MCPcopy Create free account
hub / github.com/Graphify-Labs/graphify / test_alembic_module_docstring_suppressed

Function test_alembic_module_docstring_suppressed

tests/test_rationale.py:93–113  ·  view source on GitHub ↗
(tmp_path)

Source from the content-addressed store, hash-verified

91
92
93def test_alembic_module_docstring_suppressed(tmp_path):
94 path = _write_py(tmp_path, '''
95 """initial schema
96
97 Revision ID: 0001abcd
98 Revises:
99 Create Date: 2023-01-01 00:00:00
100 """
101 revision = "0001abcd"
102 down_revision = None
103 branch_labels = None
104
105 def upgrade():
106 pass
107
108 def downgrade():
109 pass
110 ''')
111 result = extract_python(path)
112 rationale = [n for n in result["nodes"] if n.get("file_type") == "rationale"]
113 assert not any("Revision ID" in n["label"] for n in rationale)
114
115
116def test_alembic_function_docstrings_still_extracted(tmp_path):

Callers

nothing calls this directly

Calls 3

extract_pythonFunction · 0.90
_write_pyFunction · 0.85
getMethod · 0.45

Tested by

no test coverage detected