diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-13 15:08:49 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-13 15:08:49 +0300 |
commit | 1308dc5eb484ab0f8064989fc551ebdb4b1a7976 (patch) | |
tree | 614a93d9bf8df34ecfc25c02648329987fb21dde /spec/javascripts/vue_shared | |
parent | f0707f413ce49b5712fca236b950acbec029be1e (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/javascripts/vue_shared')
-rw-r--r-- | spec/javascripts/vue_shared/components/project_selector/project_selector_spec.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/spec/javascripts/vue_shared/components/project_selector/project_selector_spec.js b/spec/javascripts/vue_shared/components/project_selector/project_selector_spec.js index 2b60ea0fd74..178df54b465 100644 --- a/spec/javascripts/vue_shared/components/project_selector/project_selector_spec.js +++ b/spec/javascripts/vue_shared/components/project_selector/project_selector_spec.js @@ -1,5 +1,5 @@ import Vue from 'vue'; -import _ from 'underscore'; +import { head } from 'lodash'; import { GlSearchBoxByType, GlInfiniteScroll } from '@gitlab/ui'; import { mount, createLocalVue } from '@vue/test-utils'; @@ -99,9 +99,9 @@ describe('ProjectSelector component', () => { it(`triggers a "projectClicked" event when a project is clicked`, () => { spyOn(vm, '$emit'); - wrapper.find(ProjectListItem).vm.$emit('click', _.first(searchResults)); + wrapper.find(ProjectListItem).vm.$emit('click', head(searchResults)); - expect(vm.$emit).toHaveBeenCalledWith('projectClicked', _.first(searchResults)); + expect(vm.$emit).toHaveBeenCalledWith('projectClicked', head(searchResults)); }); it(`shows a "no results" message if showNoResultsMessage === true`, () => { |