Commit ff186d90 authored by Laurent's avatar Laurent

Zend_Cache does not support seed with '-'

parent d83b2b98
......@@ -42,7 +42,7 @@ class Storm_Cache {
public static function setSeed($seed){
static::$_seed = $seed;
static::$_seed = str_replace('-', '_', $seed);
static::$_real_seed = null;
}
......
......@@ -74,4 +74,15 @@ class Storm_CacheTest extends PHPUnit_Framework_TestCase {
$this->assertEmpty($this->_cache->load('minions'));
}
/** @test */
public function dashShouldBeReplacedInSeedAsZendCacheDoesNotWorkWithDashSeed() {
Storm_Cache::setSeed('ban-ana');
$this->_cache->save('too much', 'minions');
$generated_seed = $this->_backend->load('ban_ana');
$this->assertContains('ban_ana_', $generated_seed);
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment