Skip to content

Commit

Permalink
Tweak tests
Browse files Browse the repository at this point in the history
  • Loading branch information
omus committed May 17, 2024
1 parent cc7bf6e commit 6d181bc
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions test/display.jl
Original file line number Diff line number Diff line change
Expand Up @@ -147,10 +147,10 @@
display(TextDisplay(buf), diff)
@test strip(String(take!(buf.io))) == "\"a{+d+}b{-c-}\""

diff = deepdiff("a\0\"\$b", "a\"\$b")
diff = deepdiff("a\0\"b", "a\"\$b")
buf = setcolor(false)
display(TextDisplay(buf), diff)
@test strip(String(take!(buf.io))) == raw"\"a{-\0-}\\\"\$b\""
@test strip(String(take!(buf.io))) == raw"\"a{-\0-}\\\"{+\$+}b\""
resetcolor()
end

Expand All @@ -159,12 +159,12 @@
differences can
be "hard" to find
\$in
\tmultiline\0
\tmultiline
output"""
s2 = """
differences can
be hurd to find
multiline
multiline\0
output"""
diff = deepdiff(s1, s2)
@testset "Color Display" begin
Expand All @@ -174,9 +174,9 @@
differences can
- be "hard" to find
- \$in
[31m- \tmultiline\0[39m
[31m- \tmultiline[39m
+ be hurd to find
[32m+ multiline[39m
[32m+ multiline\0[39m
output\"\"\""""
display(TextDisplay(buf), diff)
@test strip(String(take!(buf.io))) == expected
Expand All @@ -189,9 +189,9 @@
differences can
- be "hard" to find
- \$in
- \tmultiline\0
- \tmultiline
+ be hurd to find
+ multiline
+ multiline\0
output\"\"\""""
end
resetcolor()
Expand Down

0 comments on commit 6d181bc

Please sign in to comment.