/**
* @expectedException \BrowscapPHP\Exception\ReaderException
* @expectedExceptionMessage Cannot extract user agent string from line "Test"
*/
public function testReadNotSuccessFull()
{
$reader = $this->getMock('\\BrowscapPHP\\Util\\Logfile\\ApacheCommonLogFormatReader', array('test', 'read'), array(), '', false);
$reader->expects(self::once())->method('test')->will(self::returnValue(false));
$reader->expects(self::never())->method('read')->will(self::returnValue('TestUA'));
$this->object->addReader($reader);
$this->object->read('Test');
}