diff options
Diffstat (limited to 'spec/frontend/pages/projects/learn_gitlab/components/learn_gitlab_section_card_spec.js')
-rw-r--r-- | spec/frontend/pages/projects/learn_gitlab/components/learn_gitlab_section_card_spec.js | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/spec/frontend/pages/projects/learn_gitlab/components/learn_gitlab_section_card_spec.js b/spec/frontend/pages/projects/learn_gitlab/components/learn_gitlab_section_card_spec.js new file mode 100644 index 00000000000..de6aca08235 --- /dev/null +++ b/spec/frontend/pages/projects/learn_gitlab/components/learn_gitlab_section_card_spec.js @@ -0,0 +1,26 @@ +import { shallowMount } from '@vue/test-utils'; +import LearnGitlabSectionCard from '~/pages/projects/learn_gitlab/components/learn_gitlab_section_card.vue'; +import { testActions } from './mock_data'; + +const defaultSection = 'workspace'; + +describe('Learn GitLab Section Card', () => { + let wrapper; + + afterEach(() => { + wrapper.destroy(); + wrapper = null; + }); + + const createWrapper = () => { + wrapper = shallowMount(LearnGitlabSectionCard, { + propsData: { section: defaultSection, actions: testActions }, + }); + }; + + it('renders correctly', () => { + createWrapper({ completed: false }); + + expect(wrapper.element).toMatchSnapshot(); + }); +}); |