diff options
Diffstat (limited to 'spec/frontend/pipelines/test_reports/test_suite_table_spec.js')
-rw-r--r-- | spec/frontend/pipelines/test_reports/test_suite_table_spec.js | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/spec/frontend/pipelines/test_reports/test_suite_table_spec.js b/spec/frontend/pipelines/test_reports/test_suite_table_spec.js index a5b093cf769..65bffe7039a 100644 --- a/spec/frontend/pipelines/test_reports/test_suite_table_spec.js +++ b/spec/frontend/pipelines/test_reports/test_suite_table_spec.js @@ -1,11 +1,14 @@ import Vuex from 'vuex'; -import { shallowMount } from '@vue/test-utils'; +import { shallowMount, createLocalVue } from '@vue/test-utils'; import { getJSONFixture } from 'helpers/fixtures'; import SuiteTable from '~/pipelines/components/test_reports/test_suite_table.vue'; import * as getters from '~/pipelines/stores/test_reports/getters'; import { TestStatus } from '~/pipelines/constants'; import skippedTestCases from './mock_data'; +const localVue = createLocalVue(); +localVue.use(Vuex); + describe('Test reports suite table', () => { let wrapper; let store; @@ -25,13 +28,17 @@ describe('Test reports suite table', () => { const createComponent = (suite = testSuite) => { store = new Vuex.Store({ state: { - selectedSuite: suite, + testReports: { + test_suites: [suite], + }, + selectedSuiteIndex: 0, }, getters, }); wrapper = shallowMount(SuiteTable, { store, + localVue, }); }; |