From 85c1f8a9e09348741b8a162882e5b94f7a3e830f Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Thu, 7 Mar 2019 10:47:09 +0900 Subject: Always prepend ANSI reset code before re-assembling tokens --- src/ansi_test.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/ansi_test.go') diff --git a/src/ansi_test.go b/src/ansi_test.go index 5acbc131..e10893c9 100644 --- a/src/ansi_test.go +++ b/src/ansi_test.go @@ -167,8 +167,8 @@ func TestAnsiCodeStringConversion(t *testing.T) { strings.Replace(state.ToString(), "\x1b[", "\\x1b[", -1)) } } - assert("\x1b[m", nil, "\x1b[m") - assert("\x1b[m", &ansiState{attr: tui.Blink}, "\x1b[m") + assert("\x1b[m", nil, "") + assert("\x1b[m", &ansiState{attr: tui.Blink}, "") assert("\x1b[31m", nil, "\x1b[31;49m") assert("\x1b[41m", nil, "\x1b[39;41m") -- cgit v1.2.3