Open jpzwarte opened 1 year ago
Not sure if it matters, but this is with @web/dev-server-esbuild
.
My web-test-runner.config.mjs
:
// @ts-check
import { esbuildPlugin } from '@web/dev-server-esbuild';
import { playwrightLauncher } from '@web/test-runner-playwright';
/** @type {import('@web/test-runner').TestRunnerConfig} */
const config = {
nodeResolve: true,
files: ['src/**/*.spec.ts'],
browsers: [playwrightLauncher({ product: 'chromium' })],
plugins: [esbuildPlugin({ ts: true, target: 'auto' })],
testRunnerHtml: testFramework => `
<html>
<body>
<script src="/node_modules/@webcomponents/scoped-custom-element-registry/scoped-custom-element-registry.min.js"></script>
<script type="module" src="${testFramework}"></script>
</body>
</html>
`
};
export default config;
wtr --watch