function PhpStorageFactoryTest::testGetDefault

Same name and namespace in other branches
  1. 8.9.x core/modules/system/tests/src/Kernel/PhpStorage/PhpStorageFactoryTest.php \Drupal\Tests\system\Kernel\PhpStorage\PhpStorageFactoryTest::testGetDefault()
  2. 10 core/modules/system/tests/src/Kernel/PhpStorage/PhpStorageFactoryTest.php \Drupal\Tests\system\Kernel\PhpStorage\PhpStorageFactoryTest::testGetDefault()
  3. 11.x core/modules/system/tests/src/Kernel/PhpStorage/PhpStorageFactoryTest.php \Drupal\Tests\system\Kernel\PhpStorage\PhpStorageFactoryTest::testGetDefault()

Tests the get() method using the 'default' settings.

File

core/modules/system/tests/src/Kernel/PhpStorage/PhpStorageFactoryTest.php, line 44

Class

PhpStorageFactoryTest
Tests the PHP storage factory.

Namespace

Drupal\Tests\system\Kernel\PhpStorage

Code

public function testGetDefault() {
    $this->setSettings();
    $php = PhpStorageFactory::get('test');
    $this->assertInstanceOf(MockPhpStorage::class, $php);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.