Fix tests errors and warnings - iteration 5 (#12212) (#12224)

This commit is contained in:
Michael S. Molina
2021-01-26 04:35:57 -03:00
committed by GitHub
parent 20503f92ae
commit 22d52eadb2
8 changed files with 17 additions and 5 deletions

View File

@@ -39,6 +39,7 @@ const datasource = mockDatasource['7__table'];
const SAVE_ENDPOINT = 'glob:*/api/v1/dataset/7';
const SAVE_PAYLOAD = { new: 'data' };
const SAVE_DATASOURCE_ENDPOINT = 'glob:*/datasource/save/';
const mockedProps = {
datasource,
@@ -94,6 +95,7 @@ describe('DatasourceModal', () => {
it('saves on confirm', async () => {
const callsP = fetchMock.post(SAVE_ENDPOINT, SAVE_PAYLOAD);
fetchMock.post(SAVE_DATASOURCE_ENDPOINT, {});
act(() => {
wrapper
.find('button[data-test="datasource-modal-save"]')