From dcfe7794c69f59fc0ad0c709124852f44b665a5f Mon Sep 17 00:00:00 2001 From: John Blackbourn Date: Sun, 20 Aug 2017 12:30:26 +0000 Subject: [PATCH] Build/Test tools: Don't skip tests which rely on OpenSSL when the `openssl` extension isn't loaded. See #41676 git-svn-id: https://develop.svn.wordpress.org/trunk@41278 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/tests/http/functions.php | 2 +- tests/phpunit/tests/image/functions.php | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/phpunit/tests/http/functions.php b/tests/phpunit/tests/http/functions.php index 79e0727460..0b178f8fd3 100644 --- a/tests/phpunit/tests/http/functions.php +++ b/tests/phpunit/tests/http/functions.php @@ -7,7 +7,7 @@ class Tests_HTTP_Functions extends WP_UnitTestCase { public function setUp() { if ( ! extension_loaded( 'openssl' ) ) { - $this->markTestSkipped( 'Tests_HTTP_Functions requires openssl.' ); + $this->fail( 'Tests_HTTP_Functions requires openssl.' ); } parent::setUp(); diff --git a/tests/phpunit/tests/image/functions.php b/tests/phpunit/tests/image/functions.php index 27bdbf3181..e36f7a2108 100644 --- a/tests/phpunit/tests/image/functions.php +++ b/tests/phpunit/tests/image/functions.php @@ -308,7 +308,7 @@ class Tests_Image_Functions extends WP_UnitTestCase { $this->fail( 'jpeg support unavailable' ); if ( ! extension_loaded( 'openssl' ) ) { - $this->markTestSkipped( 'Tests_Image_Functions::test_wp_crop_image_url() requires openssl.' ); + $this->fail( 'Tests_Image_Functions::test_wp_crop_image_url() requires openssl.' ); } $file = wp_crop_image( 'https://asdftestblog1.files.wordpress.com/2008/04/canola.jpg', @@ -332,7 +332,7 @@ class Tests_Image_Functions extends WP_UnitTestCase { public function test_wp_crop_image_url_not_exist() { if ( ! extension_loaded( 'openssl' ) ) { - $this->markTestSkipped( 'Tests_Image_Functions::test_wp_crop_image_url_not_exist() requires openssl.' ); + $this->fail( 'Tests_Image_Functions::test_wp_crop_image_url_not_exist() requires openssl.' ); } $file = wp_crop_image( 'https://asdftestblog1.files.wordpress.com/2008/04/canoladoesnotexist.jpg',