(self, pytester: Pytester, color_mapping)
| 2367 | |
| 2368 | class TestCodeHighlight: |
| 2369 | def test_code_highlight_simple(self, pytester: Pytester, color_mapping) -> None: |
| 2370 | pytester.makepyfile( |
| 2371 | """ |
| 2372 | def test_foo(): |
| 2373 | assert 1 == 10 |
| 2374 | """ |
| 2375 | ) |
| 2376 | result = pytester.runpytest("--color=yes") |
| 2377 | result.stdout.fnmatch_lines( |
| 2378 | color_mapping.format_for_fnmatch( |
| 2379 | [ |
| 2380 | " {kw}def{hl-reset} {function}test_foo{hl-reset}():", |
| 2381 | "> {kw}assert{hl-reset} {number}1{hl-reset} == {number}10{hl-reset}", |
| 2382 | "{bold}{red}E assert 1 == 10{reset}", |
| 2383 | ] |
| 2384 | ) |
| 2385 | ) |
| 2386 | |
| 2387 | def test_code_highlight_continuation( |
| 2388 | self, pytester: Pytester, color_mapping |
nothing calls this directly
no test coverage detected