Make WordPress Core

Changeset 55613


Ignore:
Timestamp:
03/30/2023 12:15:36 PM (2 years ago)
Author:
spacedmonkey
Message:

Tests: Fix tests introduced in [55612].

In [55612] a change was added that made two unit tests fail. Fix these test by forcing get_merged_data method to run.

Props spacedmonkey, mukesh27.
See #57814.

Location:
trunk/tests/phpunit/tests
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/theme/wpThemeJsonResolver.php

    r55448 r55613  
    730730        // Test that get_theme_data() returns a WP_Theme_JSON object.
    731731        $theme_json_resolver = new WP_Theme_JSON_Resolver();
    732         $theme_data          = $theme_json_resolver->get_theme_data();
     732        $theme_json_resolver->get_merged_data();
     733        $theme_data = $theme_json_resolver->get_theme_data();
    733734        $this->assertInstanceOf( 'WP_Theme_JSON', $theme_data, 'Theme data should be an instance of WP_Theme_JSON.' );
    734735
  • trunk/tests/phpunit/tests/webfonts/wpThemeJsonWebfontsHandler.php

    r55314 r55613  
    132132        do_action( 'after_setup_theme' );
    133133        wp_clean_theme_json_cache();
     134        do_action( 'plugins_loaded' );
    134135        do_action( 'wp_loaded' );
    135136        do_action( 'wp_enqueue_scripts' );
Note: See TracChangeset for help on using the changeset viewer.