From 5785a60ec59bec9be555016a6259945f9add341b Mon Sep 17 00:00:00 2001
From: Erick Hitter <git-contrib@ethitter.com>
Date: Sat, 11 Jun 2022 13:55:50 -0700
Subject: [PATCH] Fix fatal in test run under PHP 8

```
Fatal error: Declaration of PostFilters::setUp() must be compatible with Yoast\PHPUnitPolyfills\TestCases\TestCase::setUp(): void in /builds/wp-plugins/view-all-posts-pages/tests/test-post-filters.php on line 40
```
---
 tests/test-post-filters.php | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/tests/test-post-filters.php b/tests/test-post-filters.php
index cdcfd35..ae70028 100755
--- a/tests/test-post-filters.php
+++ b/tests/test-post-filters.php
@@ -36,11 +36,10 @@ class PostFilters extends WP_UnitTestCase {
 
 	/**
 	 * Prepare data for tests.
-	 *
-	 * Not using `setUp` because Yoast polyfills add a return type for PHP 8
-	 * that isn't supported before PHP 7.1.
 	 */
-	protected function set_up() {
+	public function set_up() {
+		parent::set_up();
+
 		static::$post_id = $this->factory->post->create(
 			array(
 				'post_title'   => 'Pagination Test',
-- 
GitLab