Workflow test base class.
Definition at line 129 of file Tools/WorkflowTestRunner/python/Test.py.
◆ __init__()
Definition at line 132 of file Tools/WorkflowTestRunner/python/Test.py.
132 def __init__(self, ID: str, run: WorkflowRun, type: WorkflowType, steps: List[str], setup: TestSetup) ->
None:
133 if not hasattr(self,
"ID"):
136 if not hasattr(self,
"tag"):
139 if not hasattr(self,
"steps"):
143 raise NotImplementedError(
"Command needs to be defined")
145 if not hasattr(self,
"output_checks"):
146 self.output_checks = []
148 if not hasattr(self,
"digest_checks"):
149 self.digest_checks = []
151 if not hasattr(self,
"skip_performance_checks"):
152 self.skip_performance_checks =
False
157 self.logger = setup.logger
158 self.validation_path: Path = self.setup.validation_run_path / f
"run_{self.ID}"
159 self.reference_path: Path = self.setup.reference_run_path / f
"run_{self.ID}"
◆ run_checks()
bool python.Test.WorkflowTest.run_checks |
( |
|
self, |
|
|
List[WorkflowCheck] |
performance_checks |
|
) |
| |
Definition at line 198 of file Tools/WorkflowTestRunner/python/Test.py.
198 def run_checks(self, performance_checks: List[WorkflowCheck]) -> bool:
199 self.logger.
info(
"-----------------------------------------------------")
200 self.logger.
info(f
"----------- Post-processing of {self.ID} Test -----------")
204 for check
in self.digest_checks:
205 result = check.run(self)
and result
208 if not self.setup.disable_output_checks:
209 for check
in self.output_checks:
210 result = check.run(self)
and result
212 if self.setup.validation_only
or self.skip_performance_checks:
216 for check
in performance_checks:
217 result = check.run(self)
and result
◆ run_reference()
None python.Test.WorkflowTest.run_reference |
( |
|
self | ) |
|
Definition at line 161 of file Tools/WorkflowTestRunner/python/Test.py.
161 def run_reference(self) -> None:
162 self.logger.
info(f
"Running reference in rel {self.setup.release_reference}")
163 self.logger.
info(f
"\"{self.command}\"")
165 self.reference_path.
mkdir(parents=
True, exist_ok=
True)
167 cmd = (f
"cd {self.reference_path};"
168 f
"source $AtlasSetup/scripts/asetup.sh {self.setup.release_reference} >& /dev/null;")
169 cmd += f
"TRF_NOECHO=1 {self.command} > {self.ID}.log 2>&1"
171 subprocess.call(cmd, shell=
True)
173 self.logger.
info(f
"Finished clean in rel {self.setup.release_reference}")
174 self.logger.
info(f
"\"{self.command}\"")
◆ run_validation()
None python.Test.WorkflowTest.run_validation |
( |
|
self | ) |
|
Definition at line 176 of file Tools/WorkflowTestRunner/python/Test.py.
176 def run_validation(self) -> None:
177 self.logger.
info(f
"Running validation in rel {self.setup.release_validation}")
178 self.logger.
info(f
"\"{self.command}\"")
180 self.validation_path.
mkdir(parents=
True, exist_ok=
True)
182 cmd = f
"cd {self.validation_path};"
183 if self.setup.disable_release_setup
or not self.setup.release_validation:
185 elif "WorkDir_DIR" in environ:
186 cmake_build_dir = environ[
"WorkDir_DIR"]
187 cmd += (f
"source $AtlasSetup/scripts/asetup.sh {self.setup.release_validation} >& /dev/null;"
188 f
"source {cmake_build_dir}/setup.sh;")
190 cmd += f
"source $AtlasSetup/scripts/asetup.sh {self.setup.release_validation} >& /dev/null;"
191 cmd += f
"TRF_NOECHO=1 {self.command} > {self.ID}.log 2>&1"
193 subprocess.call(cmd, shell=
True)
195 self.logger.
info(f
"Finished validation in rel {self.setup.release_validation}")
196 self.logger.
info(f
"\"{self.command}\"")
◆ digest_checks
python.Test.WorkflowTest.digest_checks |
◆ ID
python.Test.WorkflowTest.ID |
◆ logger
python.Test.WorkflowTest.logger |
◆ output_checks
python.Test.WorkflowTest.output_checks |
◆ run
python.Test.WorkflowTest.run |
◆ setup
python.Test.WorkflowTest.setup |
◆ skip_performance_checks
python.Test.WorkflowTest.skip_performance_checks |
◆ steps
python.Test.WorkflowTest.steps |
◆ tag
python.Test.WorkflowTest.tag |
◆ type
python.Test.WorkflowTest.type |
The documentation for this class was generated from the following file: