/** * @expectedException \InvalidArgumentException */ public function testNegativeIncrement() { $this->cache->increment('test'); $this->cache->increment('test', -100); }
/** * {@inheritdoc} */ public function increment($key, $value = 1) { $newValue = $this->cache->increment($key, $value); $this->hot[$key] = $newValue; return $newValue; }