public function testSqliteFileExistsNotWritable()
{
$file = 'app/database/bolt.db';
$dir = dirname($file);
$databaseConfig = ['driver' => 'pdo_sqlite', 'path' => $file];
$this->config->get('general/database')->willReturn($databaseConfig);
$this->extensionController->databasePath('file', $file, 'is not writable')->shouldBeCalled();
$this->_filesystem->expects($this->at(0))->method('file_exists')->with($file)->will($this->returnValue(true));
$this->_filesystem->expects($this->once())->method('touch')->with($file);
$this->_validation->expects($this->once())->method('extension_loaded')->will($this->returnValue(true));
$this->validator->check('database');
}