From 2cb6997d84600baee52b97cf9142f75e21f45185 Mon Sep 17 00:00:00 2001 From: Amir Golparvar Date: Wed, 23 Oct 2024 17:39:52 +0200 Subject: [PATCH] fix pipeline --- tests/schema_packages/labfolder/test_labfolder.py | 6 +++--- tests/schema_packages/openbis/test_openbis.py | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/tests/schema_packages/labfolder/test_labfolder.py b/tests/schema_packages/labfolder/test_labfolder.py index d0e285c..e5028f8 100644 --- a/tests/schema_packages/labfolder/test_labfolder.py +++ b/tests/schema_packages/labfolder/test_labfolder.py @@ -226,15 +226,15 @@ def mock_labfolder_response_method(*args, **kwargs): labfolder_instance.resync_labfolder_repository = True test_archive.data = labfolder_instance - if status_code is 200: + if status_code == 200: labfolder_instance.normalize(test_archive, logger=logger) - assert len(labfolder_instance.entries) is 1 + assert len(labfolder_instance.entries) == 1 assert labfolder_instance.labfolder_email is None assert labfolder_instance.password is None parsed_data = labfolder_instance.entries[0].elements[0].m_to_dict() del parsed_data['m_def'] - if parsed_data['element_type'] is not 'DATA': + if parsed_data['element_type'] != 'DATA': assert json.dumps(parsed_data, sort_keys=True) == json.dumps( response_data, sort_keys=True ) diff --git a/tests/schema_packages/openbis/test_openbis.py b/tests/schema_packages/openbis/test_openbis.py index f4055e5..3f932d5 100644 --- a/tests/schema_packages/openbis/test_openbis.py +++ b/tests/schema_packages/openbis/test_openbis.py @@ -160,9 +160,9 @@ def mock_openbis_response(*args, **kwargs): openbis_instance.password = password test_archive.data = openbis_instance - if status_code is 200: + if status_code == 200: openbis_instance.normalize(test_archive, logger=logger) - assert len(openbis_instance.spaces) is 1 + assert len(openbis_instance.spaces) == 1 assert openbis_instance.username is None assert openbis_instance.password is None @@ -178,6 +178,6 @@ def mock_openbis_response(*args, **kwargs): assert json.dumps(parsed_openbis_experiments, sort_keys=True) == json.dumps( experiment_data, sort_keys=True ) - if status_code is 400: + if status_code == 400: with pytest.raises(OpenbisImportError): openbis_instance.normalize(test_archive, logger=logger)