diff options
author | kennytm <kennytm@gmail.com> | 2018-01-30 03:14:55 +0800 |
---|---|---|
committer | Andrew Gallant <jamslam@gmail.com> | 2018-01-29 14:14:55 -0500 |
commit | 8514d4fbb45265c263c982d5107216eefb2017dc (patch) | |
tree | 606fedf1b7f6f4747644d98a0cc2128b829ea631 /tests | |
parent | ed9150c9b460115fffce151f5119a1e0f94af575 (diff) |
termcolor: tweak reset escape
Write `Ansi::reset()` using `\x1b[0m` instead of `\x1b[m`.
This works around an AppVeyor bug: https://github.com/appveyor/ci/issues/1824
Diffstat (limited to 'tests')
-rw-r--r-- | tests/tests.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/tests.rs b/tests/tests.rs index 646b02fa..5f8fa2ec 100644 --- a/tests/tests.rs +++ b/tests/tests.rs @@ -1134,7 +1134,7 @@ clean!(regression_428_color_context_path, "foo", ".", let expected = format!( "{colored_path}:foo\n{colored_path}-bar\n", colored_path=format!( - "\x1b\x5b\x6d\x1b\x5b\x33\x35\x6d{path}\x1b\x5b\x6d", + "\x1b\x5b\x30\x6d\x1b\x5b\x33\x35\x6d{path}\x1b\x5b\x30\x6d", path=path("sherlock"))); assert_eq!(lines, expected); }); @@ -1178,9 +1178,9 @@ clean!(regression_599, "^$", "input.txt", |wd: WorkDir, mut cmd: Command| { // Technically, the expected output should only be two lines, but: // https://github.com/BurntSushi/ripgrep/issues/441 let expected = "\ -[m1[m:[m[31m[m -[m2[m:[m[31m[m -[m4[m: +[0m1[0m:[0m[31m[0m +[0m2[0m:[0m[31m[0m +[0m4[0m: "; assert_eq!(expected, lines); }); |