next.js
2502c0a4 - chore(swc-wasm): Fix and clean up various issues with swc-wasm tests (#80471)

Commit
191 days ago
chore(swc-wasm): Fix and clean up various issues with swc-wasm tests (#80471) - Follow the naming conventions of other environment variables and prefix `TEST_WASM` with `NEXT_TEST_WASM` so that there's less chance of conflicts with user code - Remove the logic in `setup-wasm.mjs` that modifies the repository (not great for running tests locally) and instead try to match the environment-variable-override behavior used for native (non-wasm) bindings via `NEXT_TEST_WASM_DIR`. - Hard-fail if `NEXT_TEST_WASM` is set and we fail to load wasm bindings instead of silently using fallback logic that loads native bindings instead. - We don't need to install `wasm-pack` with `curl | sh` for tests: `pnpm` already installs it (and pins a specific version). - The whole dance of renaming the directory from `pkg` to `pkg-nextjs` is a hack we use when publishing the package, as we're building both "web" and "nextjs" targets. We don't need to do that for tests. - Fix handling of `undefined` values in SWC options objects. - Remove hacks for Next v12.2
Author
bgw bgw
Parents
Loading