From 676757948f06be96843efc18b09af5f00a86a3e5 Mon Sep 17 00:00:00 2001 From: anurindm Date: Wed, 19 Mar 2025 11:43:21 +0300 Subject: [PATCH] [#366] Test order depends on location Signed-off-by: Dmitry Anurin --- src/frostfs_testlib/hooks.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/frostfs_testlib/hooks.py b/src/frostfs_testlib/hooks.py index c56c75a..d7e4cc8 100644 --- a/src/frostfs_testlib/hooks.py +++ b/src/frostfs_testlib/hooks.py @@ -17,7 +17,7 @@ def pytest_add_frostfs_marker(items: list[pytest.Item]): @pytest.hookimpl(trylast=True) def pytest_collection_modifyitems(items: list[pytest.Item]): # The order of running tests corresponded to the suites - items.sort(key=lambda item: item.nodeid) + items.sort(key=lambda item: item.location[0]) # Change order of tests based on @pytest.mark.order() marker def order(item: pytest.Item) -> int: