mirror of
https://github.com/Seldaek/monolog.git
synced 2025-07-31 18:30:15 +02:00
Skip mongodb extension if extension is not installed (#1825)
This commit is contained in:
@@ -14,6 +14,9 @@ namespace Monolog\Handler;
|
|||||||
use MongoDB\Driver\Manager;
|
use MongoDB\Driver\Manager;
|
||||||
use Monolog\Test\TestCase;
|
use Monolog\Test\TestCase;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @requires extension mongodb
|
||||||
|
*/
|
||||||
class MongoDBHandlerTest extends TestCase
|
class MongoDBHandlerTest extends TestCase
|
||||||
{
|
{
|
||||||
public function testConstructorShouldThrowExceptionForInvalidMongo()
|
public function testConstructorShouldThrowExceptionForInvalidMongo()
|
||||||
@@ -56,10 +59,6 @@ class MongoDBHandlerTest extends TestCase
|
|||||||
|
|
||||||
public function testHandleWithDriverManager()
|
public function testHandleWithDriverManager()
|
||||||
{
|
{
|
||||||
if (!(class_exists('MongoDB\Driver\Manager'))) {
|
|
||||||
$this->markTestSkipped('ext-mongodb not installed');
|
|
||||||
}
|
|
||||||
|
|
||||||
/* This can become a unit test once ManagerInterface can be mocked.
|
/* This can become a unit test once ManagerInterface can be mocked.
|
||||||
* See: https://jira.mongodb.org/browse/PHPC-378
|
* See: https://jira.mongodb.org/browse/PHPC-378
|
||||||
*/
|
*/
|
||||||
|
Reference in New Issue
Block a user