o: ActiveSupport::Cache::Entry :@compressedF:@expires_in0:@created_atf1358449145.2599108: @value"Ú {I" class:EFI"BundledAsset;FI"logical_path;FI"teabag/base/runner_spec.js;TI" pathname;FI"U/Users/jejacks0n/Projects/teabag/spec/javascripts/teabag/base/runner_spec.coffee;FI"content_type;FI"application/javascript;FI" mtime;FI"2013-01-11T21:52:41-07:00;FI" length;Fiú I" digest;F"%d4823498607eeecb84780f5f606dcbdbI" source;FI"ú (function() { describe("Teabag.Runner", function() { beforeEach(function() { spyOn(jasmine.getEnv(), "execute"); Teabag.Runner.run = false; return this.setupSpy = spyOn(Teabag.Runner.prototype, "setup"); }); describe("constructor", function() { it("calls setup", function() { new Teabag.Runner(); return expect(this.setupSpy).toHaveBeenCalled(); }); it("sets Teabag.Runner.run to true", function() { new Teabag.Runner(); return expect(Teabag.Runner.run).toEqual(true); }); it("sets @fixturePath to whatever was in Teabag.root", function() { var originalRoot, runner; originalRoot = Teabag.root; Teabag.root = "/path/to"; runner = new Teabag.Runner(); expect(runner.fixturePath).toEqual("/path/to/fixtures"); return Teabag.root = originalRoot; }); return it("doesn't call setup if already run", function() { Teabag.Runner.run = true; new Teabag.Runner(); return expect(this.setupSpy).wasNotCalled(); }); }); describe("#getParams", function() { return it("gets the params out of the window.location.search", function() { var runner; spyOn(String.prototype, "substring").andReturn("grep=foo&bar=baz"); runner = new Teabag.Runner(); return expect(runner.params).toEqual({ grep: "foo", bar: "baz" }); }); }); return describe("#getReporter", function() { it("returns the correct reporter when using PhantomJS", function() { var runner; runner = new Teabag.Runner(); runner.params = {}; spyOn(String.prototype, 'match').andReturn(20); return expect(runner.getReporter()).toBe(Teabag.Reporters.Console); }); it("returns the correct reporter when using the browser", function() { var runner; runner = new Teabag.Runner(); runner.params = {}; spyOn(String.prototype, 'match').andReturn(0); return expect(runner.getReporter()).toBe(Teabag.Reporters.HTML); }); return it("allows setting the param", function() { var runner; runner = new Teabag.Runner(); runner.params = { reporter: "Console" }; expect(runner.getReporter()).toBe(Teabag.Reporters.Console); runner.params = { reporter: "HTML" }; return expect(runner.getReporter()).toBe(Teabag.Reporters.HTML); }); }); }); }).call(this); ;FI"required_assets_digest;F"%3bb9838c280e658a864e85ca169e7d72I" _version;F"%ffd318ca8b794f42f5029101c2cf5d91