public function testConnectionError() { try { parent::testConnectionError(); $this->fail('Getting from a non connected redis should throw a ConnectionError'); } catch (\RedisException $e) { // everything is fine here } }