blob: 5dcf3d267ed915f2989af0c0c6a5dfb24eedca4b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
import { getByText } from '@testing-library/dom';
import { mount } from '@vue/test-utils';
import BlankState from '~/pipelines/components/pipelines_list/blank_state.vue';
describe('Pipelines Blank State', () => {
const wrapper = mount(BlankState, {
propsData: {
svgPath: 'foo',
message: 'Blank State',
},
});
it('should render svg', () => {
expect(wrapper.find('.svg-content img').attributes('src')).toEqual('foo');
});
it('should render message', () => {
expect(getByText(wrapper.element, /Blank State/i)).toBeTruthy();
});
});
|