diff --git a/Testing/SystemTests/tests/analysis/ISIS_PowderPearlTest.py b/Testing/SystemTests/tests/analysis/ISIS_PowderPearlTest.py index 3fc17b200354b822ea90fde01d86a70905b5486b..7c3c711bfb5dac7643a669049a8b6017dd94683f 100644 --- a/Testing/SystemTests/tests/analysis/ISIS_PowderPearlTest.py +++ b/Testing/SystemTests/tests/analysis/ISIS_PowderPearlTest.py @@ -55,10 +55,9 @@ class _CreateVanadiumTest(stresstesting.MantidStressTest): return True def validate(self): - return (_compare_ws(reference_file_name="ISIS_Powder_PRL98472_tt70_{}.nxs".format(self.focus_mode), - results="PEARL98472_tt70-Results-D-Grp") and - _compare_ws(reference_file_name="ISIS_Powder-PEARL00098472_splined.nxs", - results="Van_spline_data_tt70")) + return "PEARL98472_tt70-Results-D-Grp", "ISIS_Powder_PRL98472_tt70_{}.nxs".format(self.focus_mode), \ + "Van_spline_data_tt70", "ISIS_Powder-PEARL00098472_splined_{}.nxs".format(self.focus_mode) + def cleanup(self): try: @@ -111,7 +110,7 @@ class FocusTest(stresstesting.MantidStressTest): self.focus_results = run_focus() def validate(self): - return focus_validation(self.focus_results) + return self.focus_results.getName(), "ISIS_Powder-PEARL00098507_tt70Atten.nxs" def cleanup(self): try: @@ -135,7 +134,7 @@ class CreateCalTest(stresstesting.MantidStressTest): self.calibration_results = run_create_cal() def valid(self): - return ceria_validator(self.calibration_results) + return self.calibration_results.getName(), "ISIS_Powder-PEARL00098494_grouped.nxs" def cleanup(self): try: @@ -188,28 +187,6 @@ def run_focus(): perform_attenuation=True, attenuation_file_path=attenuation_path) -def focus_validation(results): - reference_file_name = "ISIS_Powder-PEARL00098507_tt70Atten.nxs" - return _compare_ws(reference_file_name=reference_file_name, results=results) - - -def ceria_validator(results): - reference_file_name = "ISIS_Powder-PEARL00098494_grouped.nxs" - return _compare_ws(reference_file_name=reference_file_name, results=results) - - -def _compare_ws(reference_file_name, results): - ref_ws = mantid.Load(Filename=reference_file_name) - - is_valid = len(results) > 0 - - if not (mantid.CompareWorkspaces(Workspace1=results, Workspace2=ref_ws)[0]): - is_valid = False - print(results.getName() + " was not equal to: " + ref_ws.getName()) - - return is_valid - - def setup_mantid_paths(): config['datasearch.directories'] += ";" + input_dir