(fixtures, fuzzy_rule_match)
| 318 | |
| 319 | @pytest.mark.e2e |
| 320 | def test_diff_json_output_e2e(fixtures, fuzzy_rule_match): |
| 321 | pth1 = fixtures.path("diffs/1_a") |
| 322 | pth2 = fixtures.path("diffs/1_b") |
| 323 | try: |
| 324 | raw_output = fixtures.get_cli_output(["diff", pth1, pth2, "-f", "json"]) |
| 325 | except FeatureDisabled as exc: |
| 326 | pytest.mark.skipif(reason=exc.args[0]) |
| 327 | |
| 328 | output = json.loads(raw_output.stdout) |
| 329 | diffs = output["diffs"] |
| 330 | |
| 331 | for match in DIFF_MATCHES: |
| 332 | assert any(fuzzy_rule_match(x, match) for x in diffs), (match, diffs) |
| 333 | |
| 334 | |
| 335 | @pytest.mark.e2e |
nothing calls this directly
no test coverage detected