@@ -61,9 +61,9 @@ def test_document_implicit_end
6161
6262 @visitor . accept s
6363
64- assert_match ( /key: value/ , @io . string )
64+ assert_include ( @io . string , "key: value" )
6565 assert_equal @io . string , s . yaml
66- assert ( / \. \. \. / !~ s . yaml )
66+ assert_not_include ( s . yaml , "..." )
6767 end
6868
6969 def test_scalar
@@ -76,7 +76,7 @@ def test_scalar
7676
7777 @visitor . accept s
7878
79- assert_match ( /hello/ , @io . string )
79+ assert_include ( @io . string , "hello" )
8080 assert_equal @io . string , s . yaml
8181 end
8282
@@ -90,8 +90,8 @@ def test_scalar_with_tag
9090
9191 @visitor . accept s
9292
93- assert_match ( /str/ , @io . string )
94- assert_match ( /hello/ , @io . string )
93+ assert_include ( @io . string , "str" )
94+ assert_include ( @io . string , "hello" )
9595 assert_equal @io . string , s . yaml
9696 end
9797
@@ -107,7 +107,7 @@ def test_sequence
107107
108108 @visitor . accept s
109109
110- assert_match ( /- hello/ , @io . string )
110+ assert_include ( @io . string , "- hello" )
111111 assert_equal @io . string , s . yaml
112112 end
113113
@@ -122,7 +122,7 @@ def test_mapping
122122
123123 @visitor . accept s
124124
125- assert_match ( /key: value/ , @io . string )
125+ assert_include ( @io . string , "key: value" )
126126 assert_equal @io . string , s . yaml
127127 end
128128
@@ -137,7 +137,7 @@ def test_alias
137137
138138 @visitor . accept s
139139
140- assert_match ( / &A key: \* A/ , @io . string )
140+ assert_include ( @io . string , " &A key: \* A" )
141141 assert_equal @io . string , s . yaml
142142 end
143143 end
0 commit comments