Changeset 48937 for trunk/tests/phpunit/tests/formatting/balanceTags.php
- Timestamp:
- 09/02/2020 12:35:36 AM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/formatting/balanceTags.php
r47122 r48937 155 155 $normalized = strtolower( $tag ); 156 156 157 $this->assert Equals( "<$normalized>inside</$normalized>", balanceTags( "<$tag>inside", true ) );157 $this->assertSame( "<$normalized>inside</$normalized>", balanceTags( "<$tag>inside", true ) ); 158 158 } 159 159 … … 163 163 */ 164 164 function test_detects_supported_custom_element_tag_names( $tag ) { 165 $this->assert Equals( "<$tag>inside</$tag>", balanceTags( "<$tag>inside", true ) );165 $this->assertSame( "<$tag>inside</$tag>", balanceTags( "<$tag>inside", true ) ); 166 166 } 167 167 … … 171 171 */ 172 172 function test_ignores_invalid_tag_names( $input, $output ) { 173 $this->assert Equals( $output, balanceTags( $input, true ) );173 $this->assertSame( $output, balanceTags( $input, true ) ); 174 174 } 175 175 … … 179 179 */ 180 180 function test_ignores_unsupported_custom_tag_names( $tag ) { 181 $this->assert Equals( "<$tag>inside", balanceTags( "<$tag>inside", true ) );181 $this->assertSame( "<$tag>inside", balanceTags( "<$tag>inside", true ) ); 182 182 } 183 183 … … 187 187 */ 188 188 function test_detects_supported_invalid_tag_names( $tag ) { 189 $this->assert Equals( "<$tag>inside</$tag>", balanceTags( "<$tag>inside", true ) );189 $this->assertSame( "<$tag>inside</$tag>", balanceTags( "<$tag>inside", true ) ); 190 190 } 191 191 … … 197 197 */ 198 198 function test_selfcloses_unclosed_known_single_tags( $tag ) { 199 $this->assert Equals( "<$tag />", balanceTags( "<$tag>", true ) );199 $this->assertSame( "<$tag />", balanceTags( "<$tag>", true ) ); 200 200 } 201 201 … … 208 208 */ 209 209 function test_selfcloses_known_single_tags_having_closing_tag( $tag ) { 210 $this->assert Equals( "<$tag />", balanceTags( "<$tag></$tag>", true ) );210 $this->assertSame( "<$tag />", balanceTags( "<$tag></$tag>", true ) ); 211 211 } 212 212 … … 233 233 234 234 foreach ( $inputs as $key => $input ) { 235 $this->assert Equals( $expected[ $key ], balanceTags( $inputs[ $key ], true ) );235 $this->assertSame( $expected[ $key ], balanceTags( $inputs[ $key ], true ) ); 236 236 } 237 237 } … … 248 248 249 249 foreach ( $inputs as $key => $input ) { 250 $this->assert Equals( $expected[ $key ], balanceTags( $inputs[ $key ], true ) );250 $this->assertSame( $expected[ $key ], balanceTags( $inputs[ $key ], true ) ); 251 251 } 252 252 } … … 261 261 262 262 foreach ( $inputs as $key => $input ) { 263 $this->assert Equals( $inputs[ $key ], balanceTags( $inputs[ $key ], true ) );263 $this->assertSame( $inputs[ $key ], balanceTags( $inputs[ $key ], true ) ); 264 264 } 265 265 } … … 281 281 282 282 foreach ( $inputs as $key => $input ) { 283 $this->assert Equals( $expected[ $key ], balanceTags( $inputs[ $key ], true ) );283 $this->assertSame( $expected[ $key ], balanceTags( $inputs[ $key ], true ) ); 284 284 } 285 285 } … … 295 295 296 296 foreach ( $inputs as $key => $input ) { 297 $this->assert Equals( $inputs[ $key ], balanceTags( $inputs[ $key ], true ) );297 $this->assertSame( $inputs[ $key ], balanceTags( $inputs[ $key ], true ) ); 298 298 } 299 299 } … … 304 304 function test_allows_immediately_nested_object_tags() { 305 305 $object = '<object id="obj1"><param name="param1"/><object id="obj2"><param name="param2"/></object></object>'; 306 $this->assert Equals( $object, balanceTags( $object, true ) );306 $this->assertSame( $object, balanceTags( $object, true ) ); 307 307 } 308 308 … … 318 318 319 319 foreach ( $inputs as $key => $input ) { 320 $this->assert Equals( $expected[ $key ], balanceTags( $inputs[ $key ], true ) );320 $this->assertSame( $expected[ $key ], balanceTags( $inputs[ $key ], true ) ); 321 321 } 322 322 } … … 333 333 334 334 foreach ( $inputs as $key => $input ) { 335 $this->assert Equals( $expected[ $key ], balanceTags( $inputs[ $key ], true ) );335 $this->assertSame( $expected[ $key ], balanceTags( $inputs[ $key ], true ) ); 336 336 } 337 337 } … … 354 354 355 355 foreach ( $inputs as $key => $input ) { 356 $this->assert Equals( $expected[ $key ], balanceTags( $inputs[ $key ], true ) );356 $this->assertSame( $expected[ $key ], balanceTags( $inputs[ $key ], true ) ); 357 357 } 358 358 } … … 373 373 374 374 foreach ( $inputs as $key => $input ) { 375 $this->assert Equals( $expected[ $key ], balanceTags( $inputs[ $key ], true ) );375 $this->assertSame( $expected[ $key ], balanceTags( $inputs[ $key ], true ) ); 376 376 } 377 377 } … … 439 439 */ 440 440 public function test_custom_elements( $source, $expected ) { 441 $this->assert Equals( $expected, balanceTags( $source, true ) );441 $this->assertSame( $expected, balanceTags( $source, true ) ); 442 442 } 443 443 }
Note: See TracChangeset
for help on using the changeset viewer.