@cnamts/vue-dot
Version:
Implementation of our Design System for the French Health Insurance
37 lines (27 loc) • 715 B
text/typescript
import Vue from 'vue';
import { Wrapper } from '@vue/test-utils';
import { mountComponent } from '@/tests';
import FileUpload from '../';
let wrapper: Wrapper<Vue>;
describe('FileUpload', () => {
it('renders correctly', () => {
wrapper = mountComponent(FileUpload);
expect(wrapper).toMatchSnapshot();
});
it('renders correctly with only one extension allowed', () => {
wrapper = mountComponent(FileUpload, {
propsData: {
allowedExtensions: ['pdf']
}
});
expect(wrapper).toMatchSnapshot();
});
it('renders correctly with the multiple prop', () => {
wrapper = mountComponent(FileUpload, {
propsData: {
multiple: true
}
});
expect(wrapper).toMatchSnapshot();
});
});