class ConsoleLoggerTest in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/symfony/console/Tests/Logger/ConsoleLoggerTest.php \Symfony\Component\Console\Tests\Logger\ConsoleLoggerTest
Console logger test.
@author Kévin Dunglas <dunglas@gmail.com>
Hierarchy
- class \Psr\Log\Test\LoggerInterfaceTest extends \Psr\Log\Test\PHPUnit_Framework_TestCase
- class \Symfony\Component\Console\Tests\Logger\ConsoleLoggerTest
Expanded class hierarchy of ConsoleLoggerTest
File
- vendor/
symfony/ console/ Tests/ Logger/ ConsoleLoggerTest.php, line 25
Namespace
Symfony\Component\Console\Tests\LoggerView source
class ConsoleLoggerTest extends LoggerInterfaceTest {
/**
* @var DummyOutput
*/
protected $output;
/**
* {@inheritdoc}
*/
public function getLogger() {
$this->output = new DummyOutput(OutputInterface::VERBOSITY_VERBOSE);
return new ConsoleLogger($this->output, array(
LogLevel::EMERGENCY => OutputInterface::VERBOSITY_NORMAL,
LogLevel::ALERT => OutputInterface::VERBOSITY_NORMAL,
LogLevel::CRITICAL => OutputInterface::VERBOSITY_NORMAL,
LogLevel::ERROR => OutputInterface::VERBOSITY_NORMAL,
LogLevel::WARNING => OutputInterface::VERBOSITY_NORMAL,
LogLevel::NOTICE => OutputInterface::VERBOSITY_NORMAL,
LogLevel::INFO => OutputInterface::VERBOSITY_NORMAL,
LogLevel::DEBUG => OutputInterface::VERBOSITY_NORMAL,
));
}
/**
* {@inheritdoc}
*/
public function getLogs() {
return $this->output
->getLogs();
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
ConsoleLoggerTest:: |
protected | property | ||
ConsoleLoggerTest:: |
public | function |
Overrides LoggerInterfaceTest:: |
|
ConsoleLoggerTest:: |
public | function |
This must return the log messages in order with a simple formatting: "<LOG LEVEL> <MESSAGE>" Overrides LoggerInterfaceTest:: |
|
LoggerInterfaceTest:: |
public | function | ||
LoggerInterfaceTest:: |
public | function | ||
LoggerInterfaceTest:: |
public | function | ||
LoggerInterfaceTest:: |
public | function | ||
LoggerInterfaceTest:: |
public | function | ||
LoggerInterfaceTest:: |
public | function | @dataProvider provideLevelsAndMessages | |
LoggerInterfaceTest:: |
public | function | ||
LoggerInterfaceTest:: |
public | function | @expectedException Psr\Log\InvalidArgumentException |