MCPcopy Index your code
hub / github.com/microsoft/SkillOpt / test_nested_json

Method test_nested_json

tests/test_json_utils.py:42–44  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

40 assert extract_json(text) == {"fallback": "yes"}
41
42 def test_nested_json(self) -> None:
43 text = '```json\n{"outer": {"inner": [1, 2, 3]}}\n```'
44 assert extract_json(text) == {"outer": {"inner": [1, 2, 3]}}
45
46 def test_no_json_returns_none(self) -> None:
47 assert extract_json("Just plain text without JSON.") is None

Callers

nothing calls this directly

Calls 1

extract_jsonFunction · 0.90

Tested by

no test coverage detected