(t *testing.T)
| 53 | } |
| 54 | |
| 55 | func TestSplitTopLevelCodeBlocks_TildeFence(t *testing.T) { |
| 56 | in := "~~~json\n{\"a\":1}\n~~~" |
| 57 | segs := splitTopLevelCodeBlocks(in) |
| 58 | require.Len(t, segs, 1) |
| 59 | assert.True(t, segs[0].isCode) |
| 60 | assert.Equal(t, "json", segs[0].lang) |
| 61 | } |
| 62 | |
| 63 | func TestCodeLanguageChip_DegradesWithoutColor(t *testing.T) { |
| 64 | // On a no-color profile the chip is plain text (no escapes), so piped |
nothing calls this directly
no test coverage detected