[ARVADOS] updated: 2.1.0-2367-g0c847cae0
Git user
git at public.arvados.org
Mon Apr 25 17:11:39 UTC 2022
Summary of changes:
sdk/cwl/tests/test_container.py | 7 +++++++
sdk/cwl/tests/test_make_output.py | 9 ++++++++-
sdk/cwl/tests/test_pathmapper.py | 7 +++++++
3 files changed, 22 insertions(+), 1 deletion(-)
via 0c847cae0cb8ad2c55cf9330b84b49ce9d54b4e8 (commit)
from 02e05f2d3f790877158fa2ae5d9ceaa7e26f22fc (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
commit 0c847cae0cb8ad2c55cf9330b84b49ce9d54b4e8
Author: Peter Amstutz <peter.amstutz at curii.com>
Date: Mon Apr 25 13:11:23 2022 -0400
17301: Add more logging handler teardown
Arvados-DCO-1.1-Signed-off-by: Peter Amstutz <peter.amstutz at curii.com>
diff --git a/sdk/cwl/tests/test_container.py b/sdk/cwl/tests/test_container.py
index 4d87d27e6..975fcdf8a 100644
--- a/sdk/cwl/tests/test_container.py
+++ b/sdk/cwl/tests/test_container.py
@@ -63,6 +63,13 @@ class TestContainer(unittest.TestCase):
cwltool.process._names = set()
arv_docker_clear_cache()
+ def tearDown(self):
+ root_logger = logging.getLogger('')
+
+ # Remove existing RuntimeStatusLoggingHandlers if they exist
+ handlers = [h for h in root_logger.handlers if not isinstance(h, arvados_cwl.executor.RuntimeStatusLoggingHandler)]
+ root_logger.handlers = handlers
+
def helper(self, runner, enable_reuse=True):
document_loader, avsc_names, schema_metadata, metaschema_loader = cwltool.process.get_schema(INTERNAL_VERSION)
diff --git a/sdk/cwl/tests/test_make_output.py b/sdk/cwl/tests/test_make_output.py
index 127b3f372..fe269592c 100644
--- a/sdk/cwl/tests/test_make_output.py
+++ b/sdk/cwl/tests/test_make_output.py
@@ -23,6 +23,13 @@ class TestMakeOutput(unittest.TestCase):
self.api = mock.MagicMock()
self.api._rootDesc = get_rootDesc()
+ def tearDown(self):
+ root_logger = logging.getLogger('')
+
+ # Remove existing RuntimeStatusLoggingHandlers if they exist
+ handlers = [h for h in root_logger.handlers if not isinstance(h, arvados_cwl.executor.RuntimeStatusLoggingHandler)]
+ root_logger.handlers = handlers
+
@mock.patch("arvados.collection.Collection")
@mock.patch("arvados.collection.CollectionReader")
def test_make_output_collection(self, reader, col):
@@ -171,4 +178,4 @@ class TestMakeOutput(unittest.TestCase):
# Check that the file name conflict is resolved and open is called for both
final.open.assert_any_call("a_file", "wb")
- final.open.assert_any_call("a_file_2", "wb")
\ No newline at end of file
+ final.open.assert_any_call("a_file_2", "wb")
diff --git a/sdk/cwl/tests/test_pathmapper.py b/sdk/cwl/tests/test_pathmapper.py
index b78e89012..cbd5ba1bc 100644
--- a/sdk/cwl/tests/test_pathmapper.py
+++ b/sdk/cwl/tests/test_pathmapper.py
@@ -32,6 +32,13 @@ class TestPathmap(unittest.TestCase):
self.api = mock.MagicMock()
self.api._rootDesc = get_rootDesc()
+ def tearDown(self):
+ root_logger = logging.getLogger('')
+
+ # Remove existing RuntimeStatusLoggingHandlers if they exist
+ handlers = [h for h in root_logger.handlers if not isinstance(h, arvados_cwl.executor.RuntimeStatusLoggingHandler)]
+ root_logger.handlers = handlers
+
def test_keepref(self):
"""Test direct keep references."""
-----------------------------------------------------------------------
hooks/post-receive
--
More information about the arvados-commits
mailing list