Compliance checklist, coverage parallel, locust teardown, docs coverage test
This commit is contained in:
@@ -18,3 +18,12 @@ def test_documented_endpoints_exist_in_app():
|
||||
|
||||
def test_target_types_known():
|
||||
assert set(TARGET_TYPES) == {"post", "join_request", "user"}
|
||||
|
||||
|
||||
def test_every_product_route_is_documented():
|
||||
from molodetz.main import app
|
||||
|
||||
documented = {(item["method"], item["path"]) for item in all_endpoints()}
|
||||
routes = {(method.upper(), path) for path, methods in app.openapi()["paths"].items() for method in methods}
|
||||
undocumented = sorted(route for route in routes - documented if not route[1].startswith("/docs"))
|
||||
assert undocumented == []
|
||||
|
||||
Reference in New Issue
Block a user