From bbc4d53cc140f6fc96746c58cae86b5e11b08bd1 Mon Sep 17 00:00:00 2001 From: MV88 Date: Thu, 19 Oct 2023 12:36:11 +0200 Subject: [PATCH] improve log --- .../epics/__tests__/geoProcessing-test.js | 30 ++++++++++--------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/web/client/epics/__tests__/geoProcessing-test.js b/web/client/epics/__tests__/geoProcessing-test.js index 9505681d454..5541a66eecc 100644 --- a/web/client/epics/__tests__/geoProcessing-test.js +++ b/web/client/epics/__tests__/geoProcessing-test.js @@ -603,22 +603,22 @@ describe('geoProcessing epics', () => { }, {}); }); it('runIntersectProcessGPTEpic with double geom collect', (done) => { - const NUM_ACTIONS = 7; - mockAxios.onGet("mockUrl?service=WFS&version=1.1.0&request=GetFeature").reply(200, GET_FEATURES); - mockAxios - .onPost("mockUrl?service=WPS&version=1.0.0&REQUEST=Execute") - .replyOnce(200, COLLECT_GEOM, { - "content-type": "application/json" - }) - .onPost("mockUrl?service=WPS&version=1.0.0&REQUEST=Execute") - .replyOnce(200, MULTIPOLYGON_FC, { + try { + const NUM_ACTIONS = 7; + mockAxios.onGet("mockUrl?service=WFS&version=1.1.0&request=GetFeature").reply(200, GET_FEATURES); + mockAxios + .onPost("mockUrl?service=WPS&version=1.0.0&REQUEST=Execute") + .replyOnce(200, COLLECT_GEOM, { + "content-type": "application/json" + }) + .onPost("mockUrl?service=WPS&version=1.0.0&REQUEST=Execute") + .replyOnce(200, MULTIPOLYGON_FC, { + "content-type": "application/json" + }); + mockAxios.onGet("mockUrl2?service=WFS&version=1.1.0&request=GetFeature").reply(200, GET_FEATURES); + mockAxios.onPost("mockUrl2?service=WPS&version=1.0.0&REQUEST=Execute").replyOnce(200, COLLECT_GEOM, { "content-type": "application/json" }); - mockAxios.onGet("mockUrl2?service=WFS&version=1.1.0&request=GetFeature").reply(200, GET_FEATURES); - mockAxios.onPost("mockUrl2?service=WPS&version=1.0.0&REQUEST=Execute").replyOnce(200, COLLECT_GEOM, { - "content-type": "application/json" - }); - try { const startActions = [runProcess(GPT_TOOL_INTERSECTION)]; testEpic(addTimeoutEpic(runIntersectProcessGPTEpic, 100), NUM_ACTIONS, startActions, actions => { @@ -672,6 +672,8 @@ describe('geoProcessing epics', () => { } }); } catch (e) { + // eslint-disable-next-line no-console + console.log(e); done(e); } });