class LoggerChannelFactoryTest
Same name and namespace in other branches
- 11.x core/tests/Drupal/Tests/Core/Logger/LoggerChannelFactoryTest.php \Drupal\Tests\Core\Logger\LoggerChannelFactoryTest
- 10 core/tests/Drupal/Tests/Core/Logger/LoggerChannelFactoryTest.php \Drupal\Tests\Core\Logger\LoggerChannelFactoryTest
- 8.9.x core/tests/Drupal/Tests/Core/Logger/LoggerChannelFactoryTest.php \Drupal\Tests\Core\Logger\LoggerChannelFactoryTest
@coversDefaultClass \Drupal\Core\Logger\LoggerChannelFactory
@group Logger
Hierarchy
- class \Drupal\Tests\UnitTestCase uses \Drupal\Tests\Traits\PhpUnitWarnings, \Drupal\Tests\PhpUnitCompatibilityTrait, \Symfony\Bridge\PhpUnit\ExpectDeprecationTrait extends \PHPUnit\Framework\TestCase
- class \Drupal\Tests\Core\Logger\LoggerChannelFactoryTest extends \Drupal\Tests\UnitTestCase
Expanded class hierarchy of LoggerChannelFactoryTest
File
-
core/
tests/ Drupal/ Tests/ Core/ Logger/ LoggerChannelFactoryTest.php, line 12
Namespace
Drupal\Tests\Core\LoggerView source
class LoggerChannelFactoryTest extends UnitTestCase {
/**
* Tests LoggerChannelFactory::get().
*
* @covers ::get
*/
public function testGet() {
$factory = new LoggerChannelFactory();
$factory->setContainer($this->createMock('Symfony\\Component\\DependencyInjection\\ContainerInterface'));
// Ensure that when called with the same argument, always the same instance
// will be returned.
$this->assertSame($factory->get('test'), $factory->get('test'));
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.