Adguardhome/client/playwright.config.ts
Eugene Burkov ddc5b1343a Pull request 2551: AGDNS-2966-add-manager-extension
Squashed commit of the following:

commit 902b8a52b9a89d5b568ab09c786179df56efdcd3
Author: Igor 🐧 Lobanov <i.lobanov@adguard.com>
Date:   Mon Dec 22 14:46:35 2025 +0300

    Pull request 2553: Fixed e2e tests
    
    Fixed e2e tests
    Changed nslookup to dig
    
    Squashed commit of the following:
    
    commit c0dcce547b34743b07e82e16184a5509bb6c98cf
    Author: Igor Lobanov <i.lobanov@adguard.com>
    Date:   Sat Dec 20 13:34:50 2025 +0100
    
        fix e2e tests
    
    commit 6ae1d02aa241255838c0c2fabd0394061f7c69ba
    Author: Igor Lobanov <i.lobanov@adguard.com>
    Date:   Sat Dec 20 13:06:51 2025 +0100
    
        fixed e2e tests
        changed nslookup to dig

commit e67ed4ccb884d025c874b8bbcb97f1c3f2ca49c9
Author: Eugene Burkov <E.Burkov@AdGuard.COM>
Date:   Fri Dec 19 18:57:39 2025 +0300

    ossvc: imp docs

commit 926719b6fbfb8ea3fd5daf51da444deda6f50b61
Author: Eugene Burkov <E.Burkov@AdGuard.COM>
Date:   Thu Dec 18 19:53:55 2025 +0300

    ossvc: imp code

commit d0d7abf92a05317aca2fa3b9ad724c0b5fbb9b03
Author: Eugene Burkov <E.Burkov@AdGuard.COM>
Date:   Wed Dec 17 18:46:57 2025 +0300

    ossvc: add ext iface, imp code
2025-12-22 14:58:58 +03:00

52 lines
1.7 KiB
TypeScript
Vendored

import { defineConfig, devices } from '@playwright/test';
import path from 'path';
import { CONFIG_FILE_PATH } from './tests/constants';
/**
* See https://playwright.dev/docs/test-configuration.
*/
export default defineConfig({
testDir: './tests/e2e',
globalSetup: path.resolve('./tests/e2e/globalSetup.ts'),
globalTeardown: path.resolve('./tests/e2e/globalTeardown.ts'),
timeout: 5000,
/* Run tests in files in parallel */
fullyParallel: true,
/* Fail the build on CI if you accidentally left test.only in the source code. */
forbidOnly: !!process.env.CI,
/* Retry on CI only */
retries: process.env.CI ? 2 : 0,
/* Opt out of parallel tests on CI. */
workers: process.env.CI ? 1 : undefined,
/* Reporter to use. See https://playwright.dev/docs/test-reporters */
reporter: [['html', { open: 'never' }]],
/* Shared settings for all the projects below. See https://playwright.dev/docs/api/class-testoptions. */
use: {
/* Base URL to use in actions like `await page.goto('/')`. */
baseURL: 'http://127.0.0.1:3000',
/* Collect trace when retrying the failed test. See https://playwright.dev/docs/trace-viewer */
trace: 'on-first-retry',
launchOptions: {
headless: true,
},
},
/* Configure projects for major browsers */
projects: [
{
name: 'chromium',
use: { ...devices['Desktop Chrome'] },
},
],
webServer: process.env.CI
? {
stdout: 'pipe',
command: `./AdGuardHome --local-frontend -v -c ${CONFIG_FILE_PATH}`,
url: 'http://127.0.0.1:3000',
cwd: '..',
timeout: 10000,
}
: undefined,
});