|
@@ 49-54 (lines=6) @@
|
| 46 |
|
/** |
| 47 |
|
* Test exception thrown when array is missing keys. |
| 48 |
|
*/ |
| 49 |
|
public function testArrayHasNoKeys(){ |
| 50 |
|
$this->expectException(InvalidArgumentException::class); |
| 51 |
|
$data = ['foo','bar']; |
| 52 |
|
$method = $this->getCacheMethod('_hasKeys'); |
| 53 |
|
$method->invokeArgs($this->cache, [$data]); |
| 54 |
|
} |
| 55 |
|
|
| 56 |
|
/** |
| 57 |
|
* Test array contains a failure. |
|
@@ 92-97 (lines=6) @@
|
| 89 |
|
/** |
| 90 |
|
* Test that string is not Traversable |
| 91 |
|
*/ |
| 92 |
|
public function testIsNotTraversable(){ |
| 93 |
|
$this->expectException(InvalidArgumentException::class); |
| 94 |
|
$data = 'some-random-string'; |
| 95 |
|
$method = $this->getCacheMethod('_isTraversable'); |
| 96 |
|
$method->invokeArgs($this->cache, [$data]); |
| 97 |
|
} |
| 98 |
|
|
| 99 |
|
/** |
| 100 |
|
* Test that instance of Iterator is traversable |