MCPcopy Create free account
hub / github.com/idank/explainshell / test_none_fields_excluded

Method test_none_fields_excluded

tests/test_manager.py:2682–2690  ·  view source on GitHub ↗

Fields set to None are omitted from the JSON (exclude_none).

(self)

Source from the content-addressed store, hash-verified

2680 self.assertEqual(data["db_after"], {"manpages": 11, "mappings": 55})
2681
2682 def test_none_fields_excluded(self) -> None:
2683 """Fields set to None are omitted from the JSON (exclude_none)."""
2684
2685 report = self._make_report(batch_manifest=None)
2686 _write_report(self._run_dir, report)
2687
2688 data = self._read_report()
2689 self.assertNotIn("batch_manifest", data)
2690 self.assertNotIn("reason", data)
2691
2692 def test_reason_embedded(self) -> None:
2693 """reason string is included in the JSON when provided."""

Callers

nothing calls this directly

Calls 3

_make_reportMethod · 0.95
_read_reportMethod · 0.95
_write_reportFunction · 0.90

Tested by

no test coverage detected