diff --git a/webapp/pages/terms-and-conditions.spec.js b/webapp/pages/terms-and-conditions.spec.js new file mode 100644 index 000000000..d6ae6dce7 --- /dev/null +++ b/webapp/pages/terms-and-conditions.spec.js @@ -0,0 +1,38 @@ +import { mount } from '@vue/test-utils' +import TermsAndConditions from './terms-and-conditions.vue' +import VueMeta from 'vue-meta' + +const localVue = global.localVue +localVue.use(VueMeta, { keyName: 'head' }) + +describe('terms-and-conditions.vue', () => { + let wrapper + let mocks + + beforeEach(() => { + mocks = { + $t: (t) => t, + } + }) + + describe('mount', () => { + const Wrapper = () => { + return mount(TermsAndConditions, { + mocks, + localVue, + }) + } + + beforeEach(() => { + wrapper = Wrapper() + }) + + it('renders', () => { + expect(wrapper.is('div')).toBe(true) + }) + + it('has correct content', () => { + expect(wrapper.vm.$metaInfo.title).toBe('site.termsAndConditions') + }) + }) +})