From 481a39ed1992edfc23c46315d214aa575696d439 Mon Sep 17 00:00:00 2001 From: abe33 Date: Fri, 12 Dec 2014 15:47:46 +0100 Subject: [PATCH] :lipstick: Extract line count in a variable --- spec/minimap-spec.coffee | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/spec/minimap-spec.coffee b/spec/minimap-spec.coffee index 3ba16601..f2f98c64 100644 --- a/spec/minimap-spec.coffee +++ b/spec/minimap-spec.coffee @@ -26,7 +26,8 @@ describe 'Minimap', -> expect(minimap.getHeight()).toEqual(20) editor.setText(largeSample) - expect(minimap.getHeight()).toEqual(editor.getLineCount() * 5) + largeLineCount = editor.getLineCount() + expect(minimap.getHeight()).toEqual(largeLineCount * 5) it 'measures the scaling factor between the editor and the minimap', -> expect(minimap.getScaleFactor()).toEqual(0.5)