public function testSetItemsFail() { $options = array('ttl' => 123); $items = array('key1' => 'value1', 'key2' => 'value2', 'key3' => 'value3'); $this->_storage->expects($this->exactly(count($items)))->method('setItem')->with($this->stringContains('key'), $this->stringContains('value'), $this->equalTo($options))->will($this->returnValue(false)); $this->assertFalse($this->_storage->setItems($items, $options)); }