Skip to content

Commit b5a2f49

Browse files
committed
Tests e2e Playwright: Enhancing globals Wait for GetCapabilities request
1 parent 9a66f8f commit b5a2f49

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

tests/end2end/playwright/globals.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,8 @@ export async function gotoMap(url, page, mapMustLoad = true, layersInTreeView =
134134
});
135135

136136
// Wait for WMS GetCapabilities
137-
await getCapabilitiesWMSPromise;
137+
let getCapabilitiesWMSRequest = await getCapabilitiesWMSPromise;
138+
await getCapabilitiesWMSRequest.response();
138139
if (mapMustLoad) {
139140
if (waitForGetLegendGraphic) {
140141
// Wait for WMS GetLegendGraphic promise
@@ -184,7 +185,9 @@ export async function reloadMap(page, check = true) {
184185
});
185186

186187
// Wait for WMS GetCapabilities
187-
await getCapabilitiesWMSPromise;
188+
let getCapabilitiesWMSRequest = await getCapabilitiesWMSPromise;
189+
await getCapabilitiesWMSRequest.response();
190+
188191
if (check) {
189192
// Wait for WMS GetLegendGraphic promise
190193
const getLegendGraphicPromise = page.waitForRequest(

0 commit comments

Comments
 (0)