diff options
Diffstat (limited to 'spec/frontend/static_site_editor/components/edit_header_spec.js')
-rw-r--r-- | spec/frontend/static_site_editor/components/edit_header_spec.js | 38 |
1 files changed, 0 insertions, 38 deletions
diff --git a/spec/frontend/static_site_editor/components/edit_header_spec.js b/spec/frontend/static_site_editor/components/edit_header_spec.js deleted file mode 100644 index 2b0fe226a0b..00000000000 --- a/spec/frontend/static_site_editor/components/edit_header_spec.js +++ /dev/null @@ -1,38 +0,0 @@ -import { shallowMount } from '@vue/test-utils'; - -import EditHeader from '~/static_site_editor/components/edit_header.vue'; -import { DEFAULT_HEADING } from '~/static_site_editor/constants'; - -import { sourceContentTitle } from '../mock_data'; - -describe('~/static_site_editor/components/edit_header.vue', () => { - let wrapper; - - const buildWrapper = (propsData = {}) => { - wrapper = shallowMount(EditHeader, { - propsData: { - ...propsData, - }, - }); - }; - - const findHeading = () => wrapper.find({ ref: 'sseHeading' }); - - beforeEach(() => { - buildWrapper(); - }); - - afterEach(() => { - wrapper.destroy(); - }); - - it('renders the default heading if there is no title prop', () => { - expect(findHeading().text()).toBe(DEFAULT_HEADING); - }); - - it('renders the title prop value in the heading', () => { - buildWrapper({ title: sourceContentTitle }); - - expect(findHeading().text()).toBe(sourceContentTitle); - }); -}); |