mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-11 12:20:22 +00:00
Tests: Prevent Twenty Seventeen from interfering with Customizer tests.
This was previously fixed in [38837], but it wasn't really the correct answer, to fix it in the theme. So, [38837] is reverted in this commit, and the Twenty Seventeen actions causing problems are unhooked before tests are run. See #38372. git-svn-id: https://develop.svn.wordpress.org/trunk@38850 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -36,6 +36,9 @@ class Test_WP_Customize_Custom_CSS_Setting extends WP_UnitTestCase {
|
||||
$this->wp_customize = new WP_Customize_Manager();
|
||||
$wp_customize = $this->wp_customize;
|
||||
|
||||
// Remove default theme actions that interfere with tests
|
||||
remove_action( 'customize_register', 'twentyseventeen_customize_register' );
|
||||
|
||||
do_action( 'customize_register', $this->wp_customize );
|
||||
$this->setting = new WP_Customize_Custom_CSS_Setting( $this->wp_customize, 'custom_css[twentysixteen]' );
|
||||
$this->wp_customize->add_setting( $this->setting );
|
||||
|
||||
Reference in New Issue
Block a user