1
0
mirror of https://github.com/Seldaek/monolog.git synced 2025-08-10 23:24:02 +02:00

support for log file locking

This commit is contained in:
Ian Babrou
2014-06-30 14:27:26 +04:00
parent f84030a009
commit 6c799b3976
2 changed files with 25 additions and 1 deletions

View File

@@ -53,6 +53,17 @@ class StreamHandlerTest extends TestCase
$handler->handle($this->getRecord());
}
/**
* @covers Monolog\Handler\StreamHandler::__construct
* @covers Monolog\Handler\StreamHandler::write
*/
public function testWriteLocking()
{
$temp = sys_get_temp_dir() . DIRECTORY_SEPARATOR . 'monolog_locked_log';
$handler = new StreamHandler($temp, Logger::DEBUG, true, null, true);
$handler->handle($this->getRecord());
}
/**
* @expectedException LogicException
* @covers Monolog\Handler\StreamHandler::__construct