diff --git a/test/api/test_tools.py b/test/api/test_tools.py index 264cd0d64f7..a1ea61d38fb 100644 --- a/test/api/test_tools.py +++ b/test/api/test_tools.py @@ -206,11 +206,7 @@ class ToolsTestCase(api.ApiTestCase): with self.dataset_populator.test_history() as history_id: history_id = self.dataset_populator.new_history() ok_hdca_id = self.dataset_collection_populator.create_list_in_history(history_id, contents=["0", "1", "0", "1"]).json()["id"] - exit_code_inputs = { - "input": {'batch': True, 'values': [{"src": "hdca", "id": ok_hdca_id}]}, - } - response = self._run("exit_code_from_file", history_id, exit_code_inputs, assert_ok=False).json() - self.dataset_populator.wait_for_history(history_id, assert_ok=False) + response = self.dataset_populator.run_exit_code_from_file(history_id, ok_hdca_id) mixed_implicit_collections = response["implicit_collections"] self.assertEquals(len(mixed_implicit_collections), 1) diff --git a/test/base/populators.py b/test/base/populators.py index 16bccfcbd9e..9ff96bb4bb4 100644 --- a/test/base/populators.py +++ b/test/base/populators.py @@ -298,6 +298,14 @@ class BaseDatasetPopulator(object): self.wait_for_history(history_id, assert_ok=True) return self.run_tool("collection_creates_list", inputs, history_id) + def run_exit_code_from_file(self, history_id, hdca_id): + exit_code_inputs = { + "input": {'batch': True, 'values': [{"src": "hdca", "id": hdca_id}]}, + } + response = self.run_tool("exit_code_from_file", exit_code_inputs, history_id, assert_ok=False).json() + self.wait_for_history(history_id, assert_ok=False) + return response + def __history_content_id(self, history_id, wait=True, **kwds): if wait: assert_ok = kwds.get("assert_ok", True) diff --git a/test/functional/tools/collection_creates_dynamic_nested.xml b/test/functional/tools/collection_creates_dynamic_nested.xml index 68edc0cc34b..40a3f50247c 100644 --- a/test/functional/tools/collection_creates_dynamic_nested.xml +++ b/test/functional/tools/collection_creates_dynamic_nested.xml @@ -1,14 +1,16 @@ - + oe1_ie1.fq ; echo "B" > oe1_ie2.fq ; echo "C" > oe2_ie1.fq ; echo "D" > oe2_ie2.fq ; echo "E" > oe3_ie1.fq ; - echo "F" > oe3_ie2.fq - + echo "F" > oe3_ie2.fq ; + sleep '$sleep_time'; + ]]> + diff --git a/test/functional/tools/collection_creates_dynamic_nested_fail.xml b/test/functional/tools/collection_creates_dynamic_nested_fail.xml index 370e85f19b6..68a44bef693 100644 --- a/test/functional/tools/collection_creates_dynamic_nested_fail.xml +++ b/test/functional/tools/collection_creates_dynamic_nested_fail.xml @@ -12,7 +12,7 @@ - +