From 27c7f4a16ef05c5e424802d5c04f667f132e22d1 Mon Sep 17 00:00:00 2001 From: Omar Selo Date: Fri, 25 Oct 2024 13:35:51 +0000 Subject: [PATCH] Remove test execution id in previous results until we use it --- backend/test_observer/controllers/test_executions/helpers.py | 1 - backend/test_observer/controllers/test_executions/models.py | 1 - .../tests/controllers/test_executions/test_get_test_results.py | 3 --- 3 files changed, 5 deletions(-) diff --git a/backend/test_observer/controllers/test_executions/helpers.py b/backend/test_observer/controllers/test_executions/helpers.py index 444e3fd3..06be5c12 100644 --- a/backend/test_observer/controllers/test_executions/helpers.py +++ b/backend/test_observer/controllers/test_executions/helpers.py @@ -34,7 +34,6 @@ def parse_previous_test_results( status=test_result.status, version=test_result.test_execution.artefact_build.artefact.version, artefact_id=test_result.test_execution.artefact_build.artefact_id, - test_execution_id=test_result.test_execution.id, ) for test_result in test_results ] diff --git a/backend/test_observer/controllers/test_executions/models.py b/backend/test_observer/controllers/test_executions/models.py index c99b87b2..60d9ade8 100644 --- a/backend/test_observer/controllers/test_executions/models.py +++ b/backend/test_observer/controllers/test_executions/models.py @@ -115,7 +115,6 @@ class PreviousTestResult(BaseModel): status: TestResultStatus version: str artefact_id: int - test_execution_id: int class TestResultDTO(BaseModel): diff --git a/backend/tests/controllers/test_executions/test_get_test_results.py b/backend/tests/controllers/test_executions/test_get_test_results.py index 85443013..93040ca4 100644 --- a/backend/tests/controllers/test_executions/test_get_test_results.py +++ b/backend/tests/controllers/test_executions/test_get_test_results.py @@ -67,7 +67,6 @@ def test_fetch_test_results(test_client: TestClient, generator: DataGenerator): "status": test_result_first.status, "version": artefact_first.version, "artefact_id": artefact_first.id, - "test_execution_id": test_execution_first.id, } ] @@ -113,7 +112,6 @@ def test_previous_results_only_uses_latest_builds( "status": tr12.status, "version": a1.version, "artefact_id": a1.id, - "test_execution_id": te12.id, } ], } @@ -152,7 +150,6 @@ def test_previous_results_shows_reruns( "status": tr1.status, "version": a.version, "artefact_id": a.id, - "test_execution_id": te1.id, } ], }