From 7bf0022d3f11dd49bab8a5cffa196ad10b9bcd66 Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Wed, 12 Dec 2012 16:39:23 -0800 Subject: [PATCH] Make the font size 16 in specs, because a few specs depend on it --- spec/app/editor-spec.coffee | 9 +++------ spec/spec-helper.coffee | 1 + 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/spec/app/editor-spec.coffee b/spec/app/editor-spec.coffee index 3ee5949ab..5bc683850 100644 --- a/spec/app/editor-spec.coffee +++ b/spec/app/editor-spec.coffee @@ -547,13 +547,10 @@ describe "Editor", -> it "updates the gutter width and font size", -> rootView.attachToDom() - originalFontSize = editor.getFontSize() - originalGutterWidth = editor.gutter.width() - - config.editor.fontSize = originalFontSize * 4 + config.editor.fontSize = 16 * 4 config.update() - expect(editor.gutter.css('font-size')).toBe "#{originalFontSize * 4}px" - expect(editor.gutter.width()).toBe(originalGutterWidth * 4) + expect(editor.gutter.css('font-size')).toBe "#{16 * 4}px" + expect(editor.gutter.width()).toBe(141) it "updates lines if there are unrendered lines", -> editor.attachToDom(heightInLines: 5) diff --git a/spec/spec-helper.coffee b/spec/spec-helper.coffee index a06bf2b63..ea1d0d8c9 100644 --- a/spec/spec-helper.coffee +++ b/spec/spec-helper.coffee @@ -26,6 +26,7 @@ beforeEach -> spyOn(config, 'load') spyOn(config, 'save') config.assignDefaults() + config.editor.fontSize = 16 # make editor display updates synchronous spyOn(Editor.prototype, 'requestDisplayUpdate').andCallFake -> @updateDisplay()