astro/packages/astro/e2e/error-react-spectrum.test.js
Tony Sullivan 1c6895884c
Testing perf improvements for e2e tests (#4354)
* WIP: testing fixes to share the dev server in e2e test suites

* temp: testing multiple workers

* Revert "temp: testing multiple workers"

This reverts commit 9c7bc9d93c9c3f6dd62e3732f878f2d86016b213.
2022-08-17 19:37:10 +00:00

23 lines
626 B
JavaScript

import { expect } from '@playwright/test';
import { testFactory, getErrorOverlayMessage } from './test-utils.js';
const test = testFactory({ root: './fixtures/error-react-spectrum/' });
let devServer;
test.beforeAll(async ({ astro }) => {
devServer = await astro.startDevServer();
});
test.afterAll(async ({ astro }) => {
await devServer.stop();
});
test.describe('Error: React Spectrum', () => {
test('overlay', async ({ page, astro }) => {
await page.goto(astro.resolveUrl('/'));
const message = await getErrorOverlayMessage(page);
expect(message).toMatch('@adobe/react-spectrum is not compatible');
});
});