We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c88ec9a commit c12c0bdCopy full SHA for c12c0bd
test/CacheTest.php
@@ -74,9 +74,20 @@ public function test_cache_expire()
74
75
public function test_namespace_is_set_properly()
76
{
77
- Cache::$options['namespace'] = 'myapp';
78
- $this->cache_get();
79
- $this->assert_same("abcd", Cache::$adapter->read("myapp::1337"));
+ Cache::$options['namespace'] = 'myapp';
+ $this->cache_get();
+ $this->assert_same("abcd", Cache::$adapter->read("myapp::1337"));
80
+ }
81
+
82
+ /**
83
+ * @expectedException ActiveRecord\CacheException
84
+ */
85
+ public function test_exception_when_connect_fails()
86
+ {
87
+ $stub = $this->getMockBuilder('ActiveRecord\Memcache')
88
+ ->setMethods(array('connect'))
89
+ ->setConstructorArgs(array(array('host' => '127.0.0.1')))
90
+ ->getMock();
91
}
92
93
?>
0 commit comments