Commit 84d6ae0e authored by Olena Horal-Koretska's avatar Olena Horal-Koretska

Merge branch 'find-migrate-ee-members' into 'master'

Replace usage of find/findAll in ee/spec/frontend/members

See merge request gitlab-org/gitlab!78649
parents 158bebbe 48ea8754
...@@ -24,7 +24,7 @@ describe('UserActionButtons', () => { ...@@ -24,7 +24,7 @@ describe('UserActionButtons', () => {
return waitForPromises(); return waitForPromises();
}; };
const findLdapOverrideButton = () => wrapper.find(LdapOverrideButton); const findLdapOverrideButton = () => wrapper.findComponent(LdapOverrideButton);
afterEach(() => { afterEach(() => {
wrapper.destroy(); wrapper.destroy();
......
...@@ -32,7 +32,7 @@ describe('UserAvatar', () => { ...@@ -32,7 +32,7 @@ describe('UserAvatar', () => {
`('renders the "$badgeText" badge', ({ member, badgeText }) => { `('renders the "$badgeText" badge', ({ member, badgeText }) => {
createComponent({ member }); createComponent({ member });
expect(wrapper.find(GlBadge).text()).toBe(badgeText); expect(wrapper.findComponent(GlBadge).text()).toBe(badgeText);
}); });
}); });
}); });
...@@ -55,7 +55,7 @@ describe('LdapDropdownItem', () => { ...@@ -55,7 +55,7 @@ describe('LdapDropdownItem', () => {
beforeEach(() => { beforeEach(() => {
createComponent(); createComponent();
wrapper.find(GlDropdownItem).find('[role="menuitem"]').trigger('click'); wrapper.findComponent(GlDropdownItem).find('[role="menuitem"]').trigger('click');
}); });
it('calls `updateLdapOverride` action', () => { it('calls `updateLdapOverride` action', () => {
......
...@@ -45,7 +45,7 @@ describe('LdapOverrideButton', () => { ...@@ -45,7 +45,7 @@ describe('LdapOverrideButton', () => {
}); });
}; };
const findButton = () => wrapper.find(GlButton); const findButton = () => wrapper.findComponent(GlButton);
beforeEach(() => { beforeEach(() => {
createComponent(); createComponent();
......
...@@ -62,7 +62,7 @@ describe('LdapOverrideConfirmationModal', () => { ...@@ -62,7 +62,7 @@ describe('LdapOverrideConfirmationModal', () => {
}); });
}; };
const findModal = () => wrapper.find(GlModal); const findModal = () => wrapper.findComponent(GlModal);
const getByText = (text, options) => const getByText = (text, options) =>
createWrapper(within(findModal().element).getByText(text, options)); createWrapper(within(findModal().element).getByText(text, options));
const getEditPermissionsButton = () => const getEditPermissionsButton = () =>
......
...@@ -16,7 +16,7 @@ describe('ExpirationDatepicker', () => { ...@@ -16,7 +16,7 @@ describe('ExpirationDatepicker', () => {
}); });
}; };
const findDatepicker = () => wrapper.find(GlDatepicker); const findDatepicker = () => wrapper.findComponent(GlDatepicker);
afterEach(() => { afterEach(() => {
wrapper.destroy(); wrapper.destroy();
......
...@@ -62,7 +62,7 @@ describe('MemberTableCell', () => { ...@@ -62,7 +62,7 @@ describe('MemberTableCell', () => {
}); });
}; };
const findWrappedComponent = () => wrapper.find(WrappedComponent); const findWrappedComponent = () => wrapper.findComponent(WrappedComponent);
afterEach(() => { afterEach(() => {
wrapper.destroy(); wrapper.destroy();
......
...@@ -24,7 +24,7 @@ describe('RoleDropdown', () => { ...@@ -24,7 +24,7 @@ describe('RoleDropdown', () => {
return waitForPromises(); return waitForPromises();
}; };
const findDropdown = () => wrapper.find(GlDropdown); const findDropdown = () => wrapper.findComponent(GlDropdown);
afterEach(() => { afterEach(() => {
wrapper.destroy(); wrapper.destroy();
...@@ -40,7 +40,7 @@ describe('RoleDropdown', () => { ...@@ -40,7 +40,7 @@ describe('RoleDropdown', () => {
member: { ...member, isOverridden: true }, member: { ...member, isOverridden: true },
}); });
expect(wrapper.find(LdapDropdownItem).exists()).toBe(true); expect(wrapper.findComponent(LdapDropdownItem).exists()).toBe(true);
}); });
}); });
...@@ -66,7 +66,7 @@ describe('RoleDropdown', () => { ...@@ -66,7 +66,7 @@ describe('RoleDropdown', () => {
}, },
}); });
expect(wrapper.find(LdapDropdownItem).exists()).toBe(false); expect(wrapper.findComponent(LdapDropdownItem).exists()).toBe(false);
}); });
}); });
}); });
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment