File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed
tests/phpunit/tests/html-api Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -17,9 +17,14 @@ class Tests_HtmlApi_WpHtmlProcessorHtml5lib extends WP_UnitTestCase {
1717 * @dataProvider data_external_html5lib_tests
1818 */
1919 public function test_external_html5lib ( $ html , $ result ) {
20+ $ processed = self ::build_html5_treelike_string ( $ html );
2021
21- $ processed_tree = self ::build_html5_treelike_string ( $ html );
22- $ this ->assertEquals ( $ processed_tree , $ result );
22+ if ( $ processed ["error " ] === "unsupported " ) {
23+ $ this ->markTestSkipped ();
24+ return ;
25+ }
26+
27+ $ this ->assertEquals ( $ processed ["output " ], $ result );
2328 }
2429
2530
@@ -60,7 +65,7 @@ static function build_html5_treelike_string( $html ) {
6065 $ output .= "< {$ t }> \n" ;
6166 }
6267
63- return $ output ;
68+ return [ " output " => $ output, " error " => $ p -> get_last_error () ] ;
6469 }
6570
6671 static function parse_html5_dat_testfile ( $ filename ) {
You can’t perform that action at this time.
0 commit comments