Skip to content
代码片段 群组 项目
未验证 提交 07a7791b 编辑于 作者: Elwyn Benson's avatar Elwyn Benson 提交者: GitLab
浏览文件

Merge branch '499631-vue3-migration-form_custom_headers_spec' into 'master'

Fix Vue 3 failing test form_custom_headers_spec

See merge request https://gitlab.com/gitlab-org/gitlab/-/merge_requests/169514



Merged-by: default avatarElwyn Benson <ebenson@gitlab.com>
Approved-by: default avatarEduardo Bonet <ebonet@gitlab.com>
Approved-by: default avatarElwyn Benson <ebenson@gitlab.com>
Co-authored-by: default avatarArtur Fedorov <afedorov@gitlab.com>
No related branches found
No related tags found
无相关合并请求
......@@ -3,8 +3,8 @@ import { nextTick } from 'vue';
import { scrollToElement } from '~/lib/utils/common_utils';
import FormCustomHeaders from '~/webhooks/components/form_custom_headers.vue';
import FormCustomHeaderItem from '~/webhooks/components/form_custom_header_item.vue';
import { mountExtended } from 'helpers/vue_test_utils_helper';
import CrudComponent from '~/vue_shared/components/crud_component.vue';
import { shallowMountExtended } from 'helpers/vue_test_utils_helper';
import { setHTMLFixture, resetHTMLFixture } from 'helpers/fixtures';
jest.mock('~/lib/utils/common_utils');
......@@ -24,8 +24,11 @@ describe('FormCustomHeaders', () => {
});
const createComponent = ({ props } = {}) => {
wrapper = mountExtended(FormCustomHeaders, {
wrapper = shallowMountExtended(FormCustomHeaders, {
propsData: props,
stubs: {
CrudComponent,
},
});
};
......@@ -49,7 +52,7 @@ describe('FormCustomHeaders', () => {
expect(findAllCustomHeaderItems()).toHaveLength(3);
const lastItem = findAllCustomHeaderItems().at(-1);
const lastItem = findAllCustomHeaderItems().at(2);
expect(lastItem.props()).toMatchObject({
headerKey: '',
headerValue: '',
......
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册