mirror of
https://github.com/ansible/awx.git
synced 2026-05-11 19:37:38 -02:30
Merge pull request #9996 from AlexSCorey/RemoveSnapShots
Removes Snapshot tests SUMMARY Removes snapshot tests ISSUE TYPE COMPONENT NAME UI AWX VERSION ADDITIONAL INFORMATION Reviewed-by: Michael Abashian <None>
This commit is contained in:
@@ -42,7 +42,6 @@ describe('<NotificationListItem canToggleNotifications />', () => {
|
|||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
);
|
);
|
||||||
expect(wrapper.find('NotificationListItem')).toMatchSnapshot();
|
|
||||||
expect(wrapper.find('Switch').length).toBe(3);
|
expect(wrapper.find('Switch').length).toBe(3);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -46,7 +46,6 @@ describe('<ToolbarDeleteButton />', () => {
|
|||||||
<ToolbarDeleteButton onDelete={() => {}} itemsToDelete={[]} />
|
<ToolbarDeleteButton onDelete={() => {}} itemsToDelete={[]} />
|
||||||
);
|
);
|
||||||
expect(wrapper.find('button')).toHaveLength(1);
|
expect(wrapper.find('button')).toHaveLength(1);
|
||||||
expect(wrapper.find('ToolbarDeleteButton')).toMatchSnapshot();
|
|
||||||
});
|
});
|
||||||
|
|
||||||
test('should open confirmation modal', async () => {
|
test('should open confirmation modal', async () => {
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -24,6 +24,5 @@ describe('<DeleteRoleConfirmationModal />', () => {
|
|||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
wrapper.update();
|
wrapper.update();
|
||||||
expect(wrapper.find('DeleteRoleConfirmationModal')).toMatchSnapshot();
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -1,6 +1,10 @@
|
|||||||
import React from 'react';
|
import React from 'react';
|
||||||
|
import { act } from 'react-dom/test-utils';
|
||||||
|
|
||||||
import { mountWithContexts } from '../../../testUtils/enzymeHelpers';
|
import {
|
||||||
|
mountWithContexts,
|
||||||
|
waitForElement,
|
||||||
|
} from '../../../testUtils/enzymeHelpers';
|
||||||
|
|
||||||
import ResourceAccessListItem from './ResourceAccessListItem';
|
import ResourceAccessListItem from './ResourceAccessListItem';
|
||||||
|
|
||||||
@@ -29,13 +33,18 @@ const accessRecord = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
describe('<ResourceAccessListItem />', () => {
|
describe('<ResourceAccessListItem />', () => {
|
||||||
test('initially renders successfully', () => {
|
test('initially renders successfully', async () => {
|
||||||
const wrapper = mountWithContexts(
|
let wrapper;
|
||||||
<ResourceAccessListItem
|
|
||||||
accessRecord={accessRecord}
|
await act(async () => {
|
||||||
onRoleDelete={() => {}}
|
wrapper = mountWithContexts(
|
||||||
/>
|
<ResourceAccessListItem
|
||||||
);
|
accessRecord={accessRecord}
|
||||||
expect(wrapper.find('ResourceAccessListItem')).toMatchSnapshot();
|
onRoleDelete={() => {}}
|
||||||
|
/>
|
||||||
|
);
|
||||||
|
});
|
||||||
|
|
||||||
|
waitForElement(wrapper, 'ResourceAccessListItem', el => el.length > 0);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user