zonemaster-gui/e2e/FR15.e2e-spec.ts
Gaël Berthaud-Müller 892c769ea4 fix test
2022-02-14 13:15:18 +01:00

21 lines
819 B
TypeScript

const { test, expect } = require('@playwright/test');
import { goToHome, setLang, showOptions } from './utils/app.utils';
test.describe('Zonemaster test FR15 - [The advanced view should look the same in latest version of different browsers]', () => {
test.beforeEach(async ({ page }) => {
await goToHome(page);
await setLang(page, 'en');
});
test('should match the domain page with options on', async ({ page}) => {
await showOptions(page);
// Force wait 0.4s, for the switch animation to finish
await page.waitForTimeout(400);
expect(await page.screenshot()).toMatchSnapshot('domain_with_options.png');
});
test('should not match the domain page with options off', async({ page }) => {
expect(await page.screenshot()).not.toMatchSnapshot('domain_with_options.png');
});
});