File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed
Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change 2222 "tests/test_polling_loop_usage.py" ,
2323 "tests/test_core_type_helper_usage.py" ,
2424 "tests/test_contributing_architecture_guard_listing.py" ,
25+ "tests/test_readme_examples_listing.py" ,
2526 "tests/test_examples_syntax.py" ,
2627 "tests/test_docs_python3_commands.py" ,
2728 "tests/test_example_sync_async_parity.py" ,
@@ -35,3 +36,14 @@ def test_architecture_guard_modules_are_marked():
3536 for module_path in ARCHITECTURE_GUARD_MODULES :
3637 module_text = Path (module_path ).read_text (encoding = "utf-8" )
3738 assert "pytestmark = pytest.mark.architecture" in module_text
39+
40+
41+ def test_architecture_guard_module_list_stays_in_sync_with_marker_files ():
42+ discovered_modules : list [str ] = []
43+ for module_path in sorted (Path ("tests" ).glob ("test_*.py" )):
44+ module_text = module_path .read_text (encoding = "utf-8" )
45+ if "pytestmark = pytest.mark.architecture" not in module_text :
46+ continue
47+ discovered_modules .append (module_path .as_posix ())
48+
49+ assert sorted (ARCHITECTURE_GUARD_MODULES ) == discovered_modules
You can’t perform that action at this time.
0 commit comments