From 0f973c28b7f4852119181b549255308c76924c4e Mon Sep 17 00:00:00 2001 From: Clement Ho Date: Fri, 6 Jan 2017 13:56:34 -0600 Subject: Fix specs --- spec/javascripts/filtered_search/dropdown_utils_spec.js.es6 | 7 ++++--- .../filtered_search/filtered_search_tokenizer_spec.js.es6 | 4 ++-- 2 files changed, 6 insertions(+), 5 deletions(-) (limited to 'spec') diff --git a/spec/javascripts/filtered_search/dropdown_utils_spec.js.es6 b/spec/javascripts/filtered_search/dropdown_utils_spec.js.es6 index 369eb90e31c..ce61b73aa8a 100644 --- a/spec/javascripts/filtered_search/dropdown_utils_spec.js.es6 +++ b/spec/javascripts/filtered_search/dropdown_utils_spec.js.es6 @@ -1,3 +1,4 @@ +//= require extensions/array //= require filtered_search/dropdown_utils //= require filtered_search/filtered_search_tokenizer //= require filtered_search/filtered_search_dropdown_manager @@ -80,7 +81,7 @@ getAttribute: () => 'value', }; - gl.DropdownUtils.setDataValueIfSelected(selected); + gl.DropdownUtils.setDataValueIfSelected(null, selected); expect(gl.FilteredSearchDropdownManager.addWordToInput.calls.count()).toEqual(1); }); @@ -89,7 +90,7 @@ getAttribute: () => 'value', }; - const result = gl.DropdownUtils.setDataValueIfSelected(selected); + const result = gl.DropdownUtils.setDataValueIfSelected(null, selected); expect(result).toBe(true); }); @@ -98,7 +99,7 @@ getAttribute: () => null, }; - const result = gl.DropdownUtils.setDataValueIfSelected(selected); + const result = gl.DropdownUtils.setDataValueIfSelected(null, selected); expect(result).toBe(false); }); }); diff --git a/spec/javascripts/filtered_search/filtered_search_tokenizer_spec.js.es6 b/spec/javascripts/filtered_search/filtered_search_tokenizer_spec.js.es6 index 8e5992fa446..ac7f8e9cbcd 100644 --- a/spec/javascripts/filtered_search/filtered_search_tokenizer_spec.js.es6 +++ b/spec/javascripts/filtered_search/filtered_search_tokenizer_spec.js.es6 @@ -24,7 +24,7 @@ expect(results.tokens[0].symbol).toBe('@'); expect(results.tokens[1].key).toBe('label'); - expect(results.tokens[1].value).toBe('Very Important'); + expect(results.tokens[1].value).toBe('"Very Important"'); expect(results.tokens[1].symbol).toBe('~'); expect(results.tokens[2].key).toBe('milestone'); @@ -72,7 +72,7 @@ expect(results.tokens[0].symbol).toBe('@'); expect(results.tokens[1].key).toBe('label'); - expect(results.tokens[1].value).toBe('Won\'t fix'); + expect(results.tokens[1].value).toBe('"Won\'t fix"'); expect(results.tokens[1].symbol).toBe('~'); expect(results.tokens[2].key).toBe('milestone'); -- cgit v1.2.1