-
-
Notifications
You must be signed in to change notification settings - Fork 320
The web-test-runner plugins don't seem to be applying #2958
Unanswered
gmzacharydovel
asked this question in
Q&A
-
Hello, I'm using the web test runner plugins, but they don't seem to change anything. Manually making a plugin seems to do something. Is there something I'm missing?
zacharydovel:~/.../eumeria-online-ordering-platform/frontend/testing2$ ../../node_modules/.bin/web-test-runner
.files/frontend/src/utils/form.test.js:
🚧 Browser logs:
SyntaxError: The requested module '/__wds-outside-root__/2/node_modules/.deno/react@19.1.0/node_modules/react/index.js' does not provide an export named 'useRef'
❌ Could not import your test module. Check the browser logs or open the browser in debug mode for more information.
.files/frontend/src/utils/start-application.test.js:
🚧 Browser logs:
SyntaxError: The requested module '/__wds-outside-root__/2/node_modules/.deno/cookie@1.0.2/node_modules/cookie/dist/index.js' does not provide an export named 'parse'
❌ Could not import your test module. Check the browser logs or open the browser in debug mode for more information.
Chrome: |██████████████████████████████| 5/5 test files | 11 passed, 0 failed
Error while running tests.
import { esbuildPlugin } from "@web/dev-server-esbuild"; import rollupCommonjs from "@rollup/plugin-commonjs"; import rollupReplace from "@rollup/plugin-replace"; import { fromRollup } from "@web/dev-server-rollup"; //import { playwrightLauncher } from "@web/test-runner-playwright"; // import { importMapsPlugin } from "@web/dev-server-import-maps"; const commonjs = fromRollup(rollupCommonjs); const replace = fromRollup(rollupReplace); const out = { // //...jasmineTestRunnerConfig(), // //testFramework: { // // config: { // // defaultTimeoutInterval: 5000, // // }, // //}, nodeResolve: true, rootDir: ".", files: [ ".files/frontend/src/**/*.test.js", //".files/frontend/src/utils/create-weak-cache.test.js" ], plugins: [ commonjs({}), esbuildPlugin({ tsx: true, ts: true, jsxFactory: "React.createElement", jsxFragment: "Fragment", }), replace({ preventAssignment: true, "include": [ "react", "react-dom/client", "react-dom", "node_modules/react-dom/client.js", ], "process.env.NODE_ENV": '"development"', "process": '{ env: { NODE_ENV: "development" } }', }), ], // // browsers: [playwrightLauncher({ product: "chromium" })], }; export default out;
Beta Was this translation helpful? Give feedback.
All reactions
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment