Merge pull request #17892 from mvdbeek/fix_assert_ok

[24.0] Make `wait_for_history_jobs` look at jobs, not datasets
This commit is contained in:
Marius van den Beek
2024-04-03 17:20:57 +02:00
committed by GitHub
3 changed files with 4 additions and 9 deletions
+1 -1
View File
@@ -5477,7 +5477,7 @@ steps:
tool_id: output_filter
state:
produce_out_1: False
filter_text_1: '1'
filter_text_1: 'foo'
produce_collection: False
""",
test_data={},
+2 -1
View File
@@ -630,7 +630,8 @@ class BaseDatasetPopulator(BasePopulator):
raise TimeoutAssertionError(message)
if assert_ok:
self.wait_for_history(history_id, assert_ok=True, timeout=timeout)
for job in self.history_jobs(history_id=history_id):
assert job["state"] in ("ok", "skipped"), f"Job {job} not in expected state"
def wait_for_jobs(
self,
+1 -7
View File
@@ -59,15 +59,9 @@ echo 'p2.reverse' > p2.reverse
</assert_contents>
</output>
</test>
<!-- tool runs with no outputs should fail -->
<test expect_num_outputs="0" expect_test_failure="true">
<test expect_num_outputs="0">
<param name="produce_out_1" value="false" />
<param name="filter_text_1" value="not_foo_or_bar" />
<output name="out_3">
<assert_contents>
<has_line line="test" />
</assert_contents>
</output>
<assert_stdout>
<has_n_lines n="0"/>
</assert_stdout>