FIX: Make test less fragile.

FIX: Make test less fragile.

diff --git a/spec/components/discourse_redis_spec.rb b/spec/components/discourse_redis_spec.rb
index a99c763..10ee9a7 100644
--- a/spec/components/discourse_redis_spec.rb
+++ b/spec/components/discourse_redis_spec.rb
@@ -175,9 +175,12 @@ describe DiscourseRedis do
     end
 
     it "should raise the right error" do
-      error = RuntimeError.new('test error')
-      Redis::Client.any_instance.expects(:call).raises(error).twice
-      2.times { expect { connector.resolve }.to raise_error(error) }
+      error = RuntimeError.new('test')
+
+      2.times do
+        expect { connector.resolve(BrokenRedis.new(error)) }
+          .to raise_error(error)
+      end
     end
   end

GitHub sha: 38ded77e