Beispiel #1
0
 public function testGetRemainingLifetimeNotFound()
 {
     $storage1 = $this->getMock('ezcCacheStackableStorage', array('reset', 'purge', 'getRemainingLifetime'));
     $storage1->expects($this->once())->method('getRemainingLifetime')->with('foo', array())->will($this->returnValue(0));
     $stack = new ezcCacheStack('foo');
     $stack->pushStorage(new ezcCacheStackStorageConfiguration('id_1', $storage1, 10, 0.5));
     $this->assertEquals(0, $stack->getRemainingLifetime('foo'));
 }