add basic type checking for LoggerConfig::GetFor
This commit is contained in:
parent
4f1d81e6fd
commit
f1052443ab
19
Tests/PHPCI/Helper/LoggerConfigTest.php
Normal file
19
Tests/PHPCI/Helper/LoggerConfigTest.php
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
class LoggerConfigTest extends PHPUnit_Framework_TestCase
|
||||||
|
{
|
||||||
|
public function testGetFor_ReturnsPSRLogger()
|
||||||
|
{
|
||||||
|
$config = new \PHPCI\Helper\LoggerConfig(array());
|
||||||
|
$logger = $config->getFor("something");
|
||||||
|
$this->assertInstanceOf('\Psr\Log\LoggerInterface', $logger);
|
||||||
|
}
|
||||||
|
|
||||||
|
public function testGetFor_ReturnsMonologInstance()
|
||||||
|
{
|
||||||
|
$config = new \PHPCI\Helper\LoggerConfig(array());
|
||||||
|
$logger = $config->getFor("something");
|
||||||
|
$this->assertInstanceOf('\Monolog\Logger', $logger);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in a new issue