@@ -55,6 +55,7 @@ public function tear_down() {
5555 * Test versioning
5656 *
5757 * @ticket 11315
58+ * @ticket 64372
5859 */
5960 public function test_wp_enqueue_style () {
6061 wp_enqueue_style ( 'no-deps-no-version ' , 'example.com ' );
@@ -63,6 +64,8 @@ public function test_wp_enqueue_style() {
6364 wp_enqueue_style ( 'no-deps-null-version-print-media ' , 'example.com ' , array (), null , 'print ' );
6465 wp_enqueue_style ( 'no-deps-arg-in-handle-with-ver?arg1=foo&arg2=bar ' , 'https://example.com/test.css ' , array (), '2.0 ' );
6566 wp_enqueue_style ( 'no-deps-arg-in-handle-without-ver?arg1=foo&arg2=bar ' , 'https://example.com/test.css ' , array (), null );
67+ wp_register_style ( 'registered-no-qs-handle-null-version-enqueued-with-qs ' , 'https://example.com/test.css ' );
68+ wp_enqueue_style ( 'registered-no-qs-handle-null-version-enqueued-with-qs?arg1=foo&arg2=bar ' );
6669
6770 $ ver = get_bloginfo ( 'version ' );
6871 $ expected = "<link rel='stylesheet' id='no-deps-no-version-css' href='http://example.com?ver= $ ver' type='text/css' media='all' /> \n" ;
@@ -71,6 +74,7 @@ public function test_wp_enqueue_style() {
7174 $ expected .= "<link rel='stylesheet' id='no-deps-null-version-print-media-css' href='http://example.com' type='text/css' media='print' /> \n" ;
7275 $ expected .= "<link rel='stylesheet' id='no-deps-arg-in-handle-with-ver-css' href='https://example.com/test.css?ver=2.0&arg1=foo&arg2=bar' type='text/css' media='all' /> \n" ;
7376 $ expected .= "<link rel='stylesheet' id='no-deps-arg-in-handle-without-ver-css' href='https://example.com/test.css?arg1=foo&arg2=bar' type='text/css' media='all' /> \n" ;
77+ $ expected .= "<link rel='stylesheet' id='registered-no-qs-handle-null-version-enqueued-with-qs-css' href='https://example.com/test.css?ver= {$ ver }&arg1=foo&arg2=bar' type='text/css' media='all' /> \n" ;
7478
7579 $ this ->assertEqualHTML ( $ expected , get_echo ( 'wp_print_styles ' ) );
7680
0 commit comments