diff --git a/tests/test_renderer_js_behaviour.py b/tests/test_renderer_js_behaviour.py index 80bfecda..d3e5c3b1 100644 --- a/tests/test_renderer_js_behaviour.py +++ b/tests/test_renderer_js_behaviour.py @@ -1014,3 +1014,19 @@ class TestRendererGateRegressions7618: assert out.count("") == 3 assert "OAuth
API keys
tokens" in out assert "LRU
60s TTL" in out + + def test_row_with_trailing_text_after_closing_pipe_matches_master(self, driver_path): + """Pins parity with master for a malformed row that has text past the last pipe. + + The downstream table regex lacks an end-of-line anchor, so it accepts a + prefix the physical-line guard rejects. Master does NOT render this as a + table either, so preserving prose here is parity, not a regression. Pinned + so a future table-guard change has to make a deliberate decision about it. + """ + out = _render(driver_path, "| h
x | n |\n|---|---| trailing") + assert "" not in out + + def test_indented_and_padded_table_still_preserves_br(self, driver_path): + out = _render(driver_path, " | a | b |\n |---|---|\n | x
y | z |") + assert "
" in out + assert "x
y" in out