From 5938c64ec72f7b0e948850cf3814eb777848cc9d Mon Sep 17 00:00:00 2001 From: Lukas Gaechter Date: Thu, 9 Nov 2023 08:55:08 +0100 Subject: [PATCH 1/2] fix: Fix failing tests for WP 6.4 --- tests/test-timber-wp-functions.php | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/tests/test-timber-wp-functions.php b/tests/test-timber-wp-functions.php index 9d984b611..a651df31b 100644 --- a/tests/test-timber-wp-functions.php +++ b/tests/test-timber-wp-functions.php @@ -12,6 +12,9 @@ public function testFunctionFire() $this->assertEquals('jared sez hi', $output); } + /** + * @expectedDeprecated the_block_template_skip_link + */ public function testFooterOnFooterFW() { global $wp_scripts; @@ -27,6 +30,9 @@ public function testFooterOnFooterFW() $this->assertSame(0, strlen($wp_footer_output1)); } + /** + * @expectedDeprecated the_block_template_skip_link + */ public function testFooterAlone() { global $wp_scripts; @@ -47,6 +53,9 @@ public function testDoubleAction() $this->assertEquals('bar', $fw1->call()); } + /** + * @expectedDeprecated the_block_template_skip_link + */ public function testDoubleActionWPFooter() { global $wp_scripts; @@ -60,6 +69,9 @@ public function testDoubleActionWPFooter() remove_action('wp_footer', 'echo_junk'); } + /** + * @expectedDeprecated the_block_template_skip_link + */ public function testInTwig() { global $wp_scripts; @@ -70,6 +82,9 @@ public function testInTwig() $this->assertGreaterThan(-1, $pos); } + /** + * @expectedDeprecated the_block_template_skip_link + */ public function testInTwigString() { global $wp_scripts; @@ -80,6 +95,9 @@ public function testInTwigString() $this->assertGreaterThan(-1, $pos); } + /** + * @expectedDeprecated the_block_template_skip_link + */ public function testAgainstFooterFunctionOutput() { global $wp_scripts; From 6fbf2748043d5302a493efdc55ab636e60f6b010 Mon Sep 17 00:00:00 2001 From: Lukas Gaechter Date: Thu, 9 Nov 2023 08:59:18 +0100 Subject: [PATCH 2/2] fix: Exclude docs folder for PHPStan --- phpstan.neon | 1 + 1 file changed, 1 insertion(+) diff --git a/phpstan.neon b/phpstan.neon index 3252253d7..43b6413de 100644 --- a/phpstan.neon +++ b/phpstan.neon @@ -8,6 +8,7 @@ parameters: - vendor/php-stubs/acf-pro-stubs/acf-pro-stubs.php excludePaths: - tests/* + - docs/* ignoreErrors: - '#Instantiated class Twig\\CacheExtension\\CacheStrategy\\GenerationalCacheStrategy not found.#' - '#Instantiated class Twig\\CacheExtension\\Extension not found.#'