for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* This file is part of the Cubiche/Metadata component.
*
* Copyright (c) Cubiche
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Cubiche\Core\Metadata\Tests\Units\Cache;
use Cubiche\Core\Metadata\Cache\FileCache;
* FileCacheTests class.
* Generated by TestGenerator on 2017-05-16 at 13:17:21.
class FileCacheTests extends CacheTestCase
{
* {@inheritdoc}
protected function createCache()
return new FileCache($this->cacheDirectory);
}
* Test create.
public function testCreate()
$this
->given($invalidCacheDir = __DIR__.'/Invalid')
->given($nonWritableCacheDir = '/root')
->then()
->exception(function () use ($invalidCacheDir) {
new FileCache($invalidCacheDir);
})->isInstanceOf(\InvalidArgumentException::class)
->exception(function () use ($nonWritableCacheDir) {
new FileCache($nonWritableCacheDir);
;