|
@@ 26-30 (lines=5) @@
|
| 23 |
|
'title' => 'title', |
| 24 |
|
); |
| 25 |
|
|
| 26 |
|
foreach ( $attributes as $name => $value ) { |
| 27 |
|
$string = "<address $name='$value'>1 WordPress Avenue, The Internet.</address>"; |
| 28 |
|
$expect_string = "<address $name='" . str_replace( '; ', ';', trim( $value, ';' ) ) . "'>1 WordPress Avenue, The Internet.</address>"; |
| 29 |
|
$this->assertEquals( $expect_string, wp_kses( $string, $allowedposttags ) ); |
| 30 |
|
} |
| 31 |
|
} |
| 32 |
|
|
| 33 |
|
/** |
|
@@ 51-55 (lines=5) @@
|
| 48 |
|
'target' => '_blank', |
| 49 |
|
); |
| 50 |
|
|
| 51 |
|
foreach ( $attributes as $name => $value ) { |
| 52 |
|
$string = "<a $name='$value'>I link this</a>"; |
| 53 |
|
$expect_string = "<a $name='" . trim( $value, ';' ) . "'>I link this</a>"; |
| 54 |
|
$this->assertEquals( $expect_string, wp_kses( $string, $allowedposttags ) ); |
| 55 |
|
} |
| 56 |
|
} |
| 57 |
|
|
| 58 |
|
/** |
|
@@ 71-75 (lines=5) @@
|
| 68 |
|
'title' => 'title', |
| 69 |
|
); |
| 70 |
|
|
| 71 |
|
foreach ( $attributes as $name => $value ) { |
| 72 |
|
$string = "<abbr $name='$value'>WP</abbr>"; |
| 73 |
|
$expect_string = "<abbr $name='" . trim( $value, ';' ) . "'>WP</abbr>"; |
| 74 |
|
$this->assertEquals( $expect_string, wp_kses( $string, $allowedposttags ) ); |
| 75 |
|
} |
| 76 |
|
} |
| 77 |
|
|
| 78 |
|
function test_feed_links() { |