diff --git a/tests/conftest.py b/tests/conftest.py index 3ddb2db..6cbbc95 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -25,7 +25,7 @@ @pytest.fixture(scope="session") def test_config(): return TestConfig( - image_name="strangebee/thehive:5.5.13", + image_name="strangebee/thehive:5.7.0", container_name="thehive4py-integration-tester", user="admin@thehive.local", password="secret", diff --git a/tests/test_procedure_endpoint.py b/tests/test_procedure_endpoint.py index ebc36a6..36ccef2 100644 --- a/tests/test_procedure_endpoint.py +++ b/tests/test_procedure_endpoint.py @@ -51,10 +51,12 @@ def test_bulk_create_in_alert_and_find( alert_id=test_alert["_id"], procedures=procedures ) + # TODO: changed the query field from `_id` to `occurDate` because since TheHive version 5.7.0 + # the `procedure._id` does not work within queries fetched_procedures = thehive.procedure.find( filters=In( - field="_id", - values=[procedure["_id"] for procedure in created_procedures], + field="occurDate", + values=[procedure["occurDate"] for procedure in created_procedures], ) ) assert sorted( @@ -99,10 +101,12 @@ def test_bulk_create_in_case_and_find( created_procedures = thehive.procedure.bulk_create_in_case( case_id=test_case["_id"], procedures=procedures ) + # TODO: changed the query field from `_id` to `occurDate` because since TheHive version 5.7.0 + # the `procedure._id` does not work within queries fetched_procedures = thehive.procedure.find( filters=In( - field="_id", - values=[procedure["_id"] for procedure in created_procedures], + field="occurDate", + values=[procedure["occurDate"] for procedure in created_procedures], ) ) assert sorted(