-
-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
15 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,6 +11,8 @@ | |
|
||
namespace Symfony\Component\Lock\Tests\Store; | ||
|
||
use PHPUnit\Framework\SkippedTestSuiteError; | ||
|
||
/** | ||
* @author Jérémy Derussé <[email protected]> | ||
* @group integration | ||
|
@@ -23,7 +25,7 @@ public static function setUpBeforeClass(): void | |
try { | ||
$redis->connect(); | ||
} catch (\Exception $e) { | ||
self::markTestSkipped($e->getMessage()); | ||
throw new SkippedTestSuiteError($e->getMessage()); | ||
} | ||
} | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,6 +11,8 @@ | |
|
||
namespace Symfony\Component\Lock\Tests\Store; | ||
|
||
use PHPUnit\Framework\SkippedTestSuiteError; | ||
|
||
/** | ||
* @author Jérémy Derussé <[email protected]> | ||
* | ||
|
@@ -22,12 +24,12 @@ class RedisArrayStoreTest extends AbstractRedisStoreTest | |
public static function setUpBeforeClass(): void | ||
{ | ||
if (!class_exists(\RedisArray::class)) { | ||
self::markTestSkipped('The RedisArray class is required.'); | ||
throw new SkippedTestSuiteError('The RedisArray class is required.'); | ||
} | ||
try { | ||
(new \Redis())->connect(getenv('REDIS_HOST')); | ||
} catch (\Exception $e) { | ||
self::markTestSkipped($e->getMessage()); | ||
throw new SkippedTestSuiteError($e->getMessage()); | ||
} | ||
} | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,6 +11,8 @@ | |
|
||
namespace Symfony\Component\Lock\Tests\Store; | ||
|
||
use PHPUnit\Framework\SkippedTestSuiteError; | ||
|
||
/** | ||
* @author Jérémy Derussé <[email protected]> | ||
* | ||
|
@@ -22,10 +24,10 @@ class RedisClusterStoreTest extends AbstractRedisStoreTest | |
public static function setUpBeforeClass(): void | ||
{ | ||
if (!class_exists(\RedisCluster::class)) { | ||
self::markTestSkipped('The RedisCluster class is required.'); | ||
throw new SkippedTestSuiteError('The RedisCluster class is required.'); | ||
} | ||
if (!getenv('REDIS_CLUSTER_HOSTS')) { | ||
self::markTestSkipped('REDIS_CLUSTER_HOSTS env var is not defined.'); | ||
throw new SkippedTestSuiteError('REDIS_CLUSTER_HOSTS env var is not defined.'); | ||
} | ||
} | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters