mirror of
https://github.com/Pathduck/gallery3.git
synced 2026-08-22 14:55:18 -04:00
Fix Cache tests for recent Cache/Database.php driver fix.
Cache::delete($arg) allows for scalars and arrays, but Cache drivers' delete($arg) function always expects an array.
This commit is contained in:
@@ -118,7 +118,7 @@ class Cache_Test extends Gallery_Unit_Test_Case {
|
||||
$value3 = array("field5" => "value5", "field6" => "value6");
|
||||
$this->_driver->set(array($id3 => $value3), array("tag3", "tag4"), 84600);
|
||||
|
||||
$this->_driver->delete($id1);
|
||||
$this->_driver->delete(array($id1));
|
||||
|
||||
$this->assert_false($this->_driver->exists($id1), "$id1 should have been deleted");
|
||||
$this->assert_true($this->_driver->exists($id2), "$id2 should not have been deleted");
|
||||
@@ -138,7 +138,7 @@ class Cache_Test extends Gallery_Unit_Test_Case {
|
||||
$value3 = array("field5" => "value5", "field6" => "value6");
|
||||
$this->_driver->set(array($id3 => $value3), array("tag3", "tag4"), 84600);
|
||||
|
||||
$data = $this->_driver->delete("tag3", true);
|
||||
$data = $this->_driver->delete_tag(array("tag3"));
|
||||
|
||||
$this->assert_true($this->_driver->exists($id1), "$id1 should not have been deleted");
|
||||
$this->assert_false($this->_driver->exists($id2), "$id2 should have been deleted");
|
||||
|
||||
Reference in New Issue
Block a user