| 376 | /** |
| 377 | * @ticket 10082 |
| 378 | * |
| 379 | * Validate ShortCode Regex identifies tags without spacing |
| 380 | * |
| 381 | */ |
| 382 | function test_shortcodes_without_spacing_simple() { |
| 383 | |
| 384 | $test_content = '[footag foo="3X"][footag foo="7X"/]'; |
| 385 | $expected = 'foo = 3Xfoo = 7X'; |
| 386 | |
| 387 | $this->assertEquals($expected, do_shortcode($test_content)); |
| 388 | |
| 389 | } |
| 390 | |
| 391 | /** |
| 392 | * @ticket 10082 |
| 393 | * |
| 394 | * Validate ShortCode Regex correctly identifies complex content |
| 395 | * that contains tags without spacing |
| 396 | */ |
| 397 | function test_shortcodes_without_spacing_complex() { |
| 398 | |
| 399 | $test_content = '[bartag foo=1][baztag][footag foo="2"][/footag] [baztag/] |
| 400 | [baztag]AZTEXT[baztag][footag foo="2"][/baztag]'; |
| 401 | |
| 402 | $expected = 'foo = 1content = foo = 2 content = |
| 403 | content = AZTEXTcontent = foo = 2'; |
| 404 | |
| 405 | $this->assertEquals($expected, do_shortcode($test_content)); |
| 406 | } |