initial impl
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
from pathlib import Path
|
||||
|
||||
|
||||
def test_python_files_are_at_most_250_lines() -> None:
|
||||
root = Path(__file__).parents[1]
|
||||
files = [*root.glob("src/**/*.py"), *root.glob("tests/**/*.py")]
|
||||
oversized = {
|
||||
str(path.relative_to(root)): len(path.read_text().splitlines())
|
||||
for path in files
|
||||
if len(path.read_text().splitlines()) > 250
|
||||
}
|
||||
assert oversized == {}
|
||||
|
||||
Reference in New Issue
Block a user