From 8f8917a99f1b430a30a0423ac761d4a837830618 Mon Sep 17 00:00:00 2001 From: Oliver Date: Tue, 7 Jan 2025 14:27:06 +0100 Subject: [PATCH] Refactor bridge mode test to not expect dialog and verify selection --- .../e2e/installed/state-dependent/custom-bridge.spec.ts | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/desktop/packages/mullvad-vpn/test/e2e/installed/state-dependent/custom-bridge.spec.ts b/desktop/packages/mullvad-vpn/test/e2e/installed/state-dependent/custom-bridge.spec.ts index 34efb60f268b..c022329e7495 100644 --- a/desktop/packages/mullvad-vpn/test/e2e/installed/state-dependent/custom-bridge.spec.ts +++ b/desktop/packages/mullvad-vpn/test/e2e/installed/state-dependent/custom-bridge.spec.ts @@ -36,10 +36,9 @@ test('App should enable bridge mode', async () => { RoutePath.openVpnSettings, ); - await page.getByTestId('bridge-mode-on').click(); - await expect(page.getByText('Enable bridge mode?')).toBeVisible(); - - await page.getByTestId('enable-confirm').click(); + const bridgeModeOnButton = page.getByTestId('bridge-mode-on'); + await bridgeModeOnButton.click(); + await expect(bridgeModeOnButton).toHaveAttribute('aria-selected', 'true'); await util.waitForNavigation(() => page.click('button[aria-label="Back"]')); await util.waitForNavigation(() => page.click('button[aria-label="Back"]'));