@@ -4,17 +4,15 @@ load 'test_helper/bats-support/load'
4
4
load ' test_helper/bats-assert/load'
5
5
load ' test_helper/util'
6
6
7
-
8
- output=$( load_fixture " chromium-modaltoelement" | $diff_so_fancy )
9
-
10
-
11
- empty_remove_highlight=" [m[1;31;48;5;52m[m[1;31m"
12
-
13
7
# https://github.com/paulirish/dotfiles/commit/6743b907ff586c28cd36e08d1e1c634e2968893e#commitcomment-13459061
14
8
@test " All removed lines are present in diff" {
15
- assert_output --partial " WebInspector.Dialog = function($empty_remove_highlight )"
16
- assert_output --partial " show: function($empty_remove_highlight )"
17
- assert_output --partial " {!Document} */ (WebInspector.Dialog._modalHostView.element.ownerDocument$empty_remove_highlight )"
9
+ output=$( load_fixture " chromium-modaltoelement" | $diff_so_fancy )
10
+ run printf " %s" " $output "
11
+
12
+ assert_line --index 7 --partial " WebInspector.Dialog"
13
+ assert_line --index 7 --partial " 5;52m" # red oldhighlight
14
+ assert_line --index 8 --partial " WebInspector.Dialog"
15
+ assert_line --index 8 --partial " 5;22m" # green newhighlight
18
16
}
19
17
20
18
@test " File with space in the name (#360)" {
@@ -28,6 +26,6 @@ empty_remove_highlight="[m[1;31;48;5;52m[m[1;31m"
28
26
output=$( load_fixture " add_remove_empty_lines" | $diff_so_fancy )
29
27
run printf " %s" " $output "
30
28
31
- assert_line --index 5 --partial " [7m[1;32"
32
- assert_line --index 8 --partial " [7m[1;31"
29
+ assert_line --index 5 --partial " [7m[1;32" # green added line
30
+ assert_line --index 8 --partial " [7m[1;31" # red removed line
33
31
}
0 commit comments