Changeset 46164 for trunk/tests/phpunit/tests/dependencies/scripts.php
- Timestamp:
- 09/18/2019 02:49:30 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/dependencies/scripts.php
r45979 r46164 45 45 wp_enqueue_script( 'empty-deps-version', 'example.com', array(), 1.2 ); 46 46 wp_enqueue_script( 'empty-deps-null-version', 'example.com', array(), null ); 47 47 48 $ver = get_bloginfo( 'version' ); 48 49 $expected = "<script type='text/javascript' src='http://example.com?ver=$ver'></script>\n"; … … 55 56 // No scripts left to print 56 57 $this->assertEquals( '', get_echo( 'wp_print_scripts' ) ); 58 } 59 60 /** 61 * @ticket 42804 62 */ 63 function test_wp_enqueue_script_with_html5_support_does_not_contain_type_attribute() { 64 add_theme_support( 'html5', array( 'script' ) ); 65 66 $GLOBALS['wp_scripts'] = new WP_Scripts(); 67 $GLOBALS['wp_scripts']->default_version = get_bloginfo( 'version' ); 68 69 wp_enqueue_script( 'empty-deps-no-version', 'example.com' ); 70 71 $ver = get_bloginfo( 'version' ); 72 $expected = "<script src='http://example.com?ver=$ver'></script>\n"; 73 74 $this->assertEquals( $expected, get_echo( 'wp_print_scripts' ) ); 57 75 } 58 76
Note: See TracChangeset
for help on using the changeset viewer.