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

Function test_empty_env

tests/test_api/test_main.py:281–291  ·  view source on GitHub ↗

Test that an empty `env` is mutated, not copied and mutated.

()

Source from the content-addressed store, hash-verified

279
280
281def test_empty_env():
282 """Test that an empty `env` is mutated, not copied and mutated."""
283 md = MarkdownIt()
284
285 env = {} # type: ignore
286 md.render("[foo]: /url\n[foo]", env)
287 assert "references" in env
288
289 env = {}
290 md.parse("[foo]: /url\n[foo]", env)
291 assert "references" in env
292
293
294def test_table_tokens(data_regression):

Callers

nothing calls this directly

Calls 3

renderMethod · 0.95
parseMethod · 0.95
MarkdownItClass · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…