From 4546c7cc33af8ed9699f81756a1e27add5e3f1b4 Mon Sep 17 00:00:00 2001 From: Michael Larabel Date: Thu, 27 Nov 2008 12:01:49 -0500 Subject: pts-core: Add validate-result mode that PTS test profiles can implement --- pts-core/functions/pts-functions-run.php | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'pts-core') diff --git a/pts-core/functions/pts-functions-run.php b/pts-core/functions/pts-functions-run.php index 412d1e5..f4b7978 100644 --- a/pts-core/functions/pts-functions-run.php +++ b/pts-core/functions/pts-functions-run.php @@ -585,6 +585,13 @@ function pts_run_test($test_identifier, $extra_arguments = "", $arguments_descri $test_results = $run_time; } + $validate_result = trim(pts_call_test_script($test_identifier, "validate-result", null, $test_results, $test_extra_runtime_variables_post)); + + if(!empty($validate_result) && !pts_string_bool($validate_result)) + { + $test_results = null; + } + if(!empty($test_results)) { $pts_test_result->add_trial_run_result(trim($test_results)); -- cgit