ArrayCacheTest.php
751 Bytes
<?php
/*
* This file is part of the Assetic package, an OpenSky project.
*
* (c) 2010-2014 OpenSky Project Inc
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Assetic\Test\Cache;
use Assetic\Cache\ArrayCache;
/**
* @group integration
*/
class ArrayCacheTest extends \PHPUnit_Framework_TestCase
{
public function testCache()
{
$cache = new ArrayCache();
$this->assertFalse($cache->has('foo'));
$cache->set('foo', 'bar');
$this->assertEquals('bar', $cache->get('foo'));
$this->assertTrue($cache->has('foo'));
$cache->remove('foo');
$this->assertFalse($cache->has('foo'));
}
}