mirror of
https://github.com/soxoj/maigret.git
synced 2026-05-06 22:19:01 +00:00
12 lines
246 B
Python
12 lines
246 B
Python
from _pytest.mark import Mark
|
|
|
|
|
|
empty_mark = Mark('', [], {})
|
|
|
|
|
|
def by_slow_marker(item):
|
|
return item.get_closest_marker('slow', default=empty_mark)
|
|
|
|
|
|
def pytest_collection_modifyitems(items):
|
|
items.sort(key=by_slow_marker, reverse=False) |