Skip to content

Commit 474fb8a

Browse files
committed
Fix test
1 parent 0699ee4 commit 474fb8a

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

tests/integration/test_empty_run.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313

1414
"""This module includes integration tests for the empty run."""
1515

16+
from datetime import datetime, timezone
1617
from unittest import mock
1718

1819
from tests import REPORT_PORTAL_SERVICE
@@ -25,6 +26,7 @@ def test_empty_run(mock_client_init):
2526
2627
:param mock_client_init: Pytest fixture
2728
"""
29+
test_start_time = datetime.now(timezone.utc)
2830
result = utils.run_pytest_tests(tests=["examples/empty/"])
2931

3032
assert int(result) == 5, "Exit code should be 5 (no tests)"
@@ -36,4 +38,4 @@ def test_empty_run(mock_client_init):
3638
finish_args = mock_client.finish_launch.call_args_list
3739
assert "status" not in finish_args[0][1], "Launch status should not be defined"
3840
launch_end_time = finish_args[0][1]["end_time"]
39-
assert launch_end_time is not None and int(launch_end_time) > 0, "Launch end time is empty"
41+
assert launch_end_time is not None and launch_end_time > test_start_time, "Launch end time is empty"

0 commit comments

Comments
 (0)