You are here

public static function MongoDbProfilerStorageTest::setUpBeforeClass in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/symfony/http-kernel/Tests/Profiler/MongoDbProfilerStorageTest.php \Symfony\Component\HttpKernel\Tests\Profiler\MongoDbProfilerStorageTest::setUpBeforeClass()

File

vendor/symfony/http-kernel/Tests/Profiler/MongoDbProfilerStorageTest.php, line 54

Class

MongoDbProfilerStorageTest

Namespace

Symfony\Component\HttpKernel\Tests\Profiler

Code

public static function setUpBeforeClass() {
  if (extension_loaded('mongo')) {
    self::$storage = new DummyMongoDbProfilerStorage('mongodb://localhost/symfony_tests/profiler_data', '', '', 86400);
    try {
      self::$storage
        ->getMongo();
    } catch (\MongoConnectionException $e) {
      self::$storage = null;
    }
  }
}