MCPcopy Create free account
hub / github.com/executablebooks/markdown-it-py / test_disable

Function test_disable

tests/test_api/test_main.py:135–149  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

133
134
135def test_disable():
136 md = MarkdownIt("zero").disable("inline")
137 assert md.get_active_rules() == {
138 "block": ["paragraph"],
139 "core": ["normalize", "block", "text_join"],
140 "inline": ["text"],
141 "inline2": ["balance_pairs", "fragments_join"],
142 }
143 md.disable(["text"])
144 assert md.get_active_rules() == {
145 "block": ["paragraph"],
146 "core": ["normalize", "block", "text_join"],
147 "inline": [],
148 "inline2": ["balance_pairs", "fragments_join"],
149 }
150
151
152def test_reset():

Callers

nothing calls this directly

Calls 3

MarkdownItClass · 0.90
disableMethod · 0.45
get_active_rulesMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…