From 78a9356b4bf31b53119e374dfbd53600d74b1e00 Mon Sep 17 00:00:00 2001 From: James Lees Date: Wed, 30 Aug 2017 09:24:00 +0100 Subject: [PATCH] Fix failing test, add test for cluster check --- spec/javascripts/unit/core/pusher_spec.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/spec/javascripts/unit/core/pusher_spec.js b/spec/javascripts/unit/core/pusher_spec.js index 5cebd104d..ab6695772 100644 --- a/spec/javascripts/unit/core/pusher_spec.js +++ b/spec/javascripts/unit/core/pusher_spec.js @@ -76,9 +76,15 @@ describe("Pusher", function() { it("should allow a hex key", function() { spyOn(Logger, "warn"); - var pusher = new Pusher("1234567890abcdef"); + var pusher = new Pusher("1234567890abcdef", { cluster: "mt1" }); expect(Logger.warn).not.toHaveBeenCalled(); }); + + it("should warn if no cluster supplied", function() { + spyOn(Logger, "warn"); + var pusher = new Pusher("1234567890abcdef"); + expect(Logger.warn).toHaveBeenCalled(); + }); }); describe("after construction", function() {