From 596c8b3f40427ab9f3db6eddba3d8e0e58e3fda1 Mon Sep 17 00:00:00 2001 From: Peter Rushforth Date: Sun, 27 Oct 2024 22:10:02 -0400 Subject: [PATCH] Adjust long touch recognition time --- test/e2e/core/touchDevice.test.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/test/e2e/core/touchDevice.test.js b/test/e2e/core/touchDevice.test.js index 724247556..30beb6e9c 100644 --- a/test/e2e/core/touchDevice.test.js +++ b/test/e2e/core/touchDevice.test.js @@ -19,7 +19,6 @@ test.describe('Playwright touch device tests', () => { }); test('Tap/Long press to show layer control', async () => { - await page.pause(); const layerControl = await page.locator( 'div > div.leaflet-control-container > div.leaflet-top.leaflet-right > div' ); @@ -43,16 +42,14 @@ test.describe('Playwright touch device tests', () => { await viewer.tap({ position: { x: 150, y: 150 } }); await layerControl.tap(); await layerControl.dispatchEvent('touchstart'); - await page.waitForTimeout(2000); + await page.waitForTimeout(1500); await layerControl.dispatchEvent('touchend'); - await page.waitForTimeout(2000); className = await layerControl.evaluate( (el) => el.classList.contains('leaflet-control-layers-expanded') && el._isExpanded ); - await page.waitForTimeout(2000); expect(className).toEqual(true); // expect the layer context menu not show after the long press