From 19273d1b995a3ec62db1f5fad227eb885f9e054e Mon Sep 17 00:00:00 2001 From: Erick Hitter <git-contrib@ethitter.com> Date: Sun, 12 May 2019 16:00:06 -0700 Subject: [PATCH] Fix tests for pre-PHP-7.1 use. --- tests/test-plugin.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/test-plugin.php b/tests/test-plugin.php index 1637419..c1681eb 100755 --- a/tests/test-plugin.php +++ b/tests/test-plugin.php @@ -26,7 +26,7 @@ class PluginTest extends WP_UnitTestCase { /** * Create a post to test with. */ - public function setUp(): void { + public function setUp() { parent::setUp(); static::$post_id_published = $this->factory->post->create(); @@ -40,7 +40,7 @@ class PluginTest extends WP_UnitTestCase { /** * Test shortlink overrides. */ - public function test_shortlink_filters(): void { + public function test_shortlink_filters() { $expected_published = user_trailingslashit( home_url( 'p/' . static::$post_id_published ) ); $expected_draft = add_query_arg( 'p', static::$post_id_draft, user_trailingslashit( home_url() ) ); @@ -51,7 +51,7 @@ class PluginTest extends WP_UnitTestCase { /** * Test redirect parsing for supported post. */ - public function test_published_post_redirect(): void { + public function test_published_post_redirect() { $fake_request = new \stdClass(); $fake_request->query_vars = [ 'p' => static::$post_id_published, @@ -67,7 +67,7 @@ class PluginTest extends WP_UnitTestCase { /** * Test redirect parsing for unsupported post. */ - public function test_draft_post_redirect(): void { + public function test_draft_post_redirect() { $fake_request = new \stdClass(); $fake_request->query_vars = [ 'p' => static::$post_id_draft, -- GitLab