jest
jest copied to clipboard
[Bug]: Failed to parse the TypeScript config file with [email protected]
Version
29.7.0
Steps to reproduce
After I upgraded typeScript
version from 5.5.4
to 5.6.2
, my test pipeline execution failed.
My execution failed pipeline is https://github.com/wtto00/android-tools/actions/runs/10907495575/job/30271298092
Expected behavior
jest --detectOpenHandles --verbose
executed successfully.
Actual behavior
jest --detectOpenHandles --verbose
execution failed, the failure information is as follows:
> @wtto00/[email protected] test E:\projects\github\wtto00\android-tools
> jest --detectOpenHandles --verbose
Error: Jest: Failed to parse the TypeScript config file E:\projects\github\wtto00\android-tools\jest.config.ts
SyntaxError: Unexpected token 'export'
at readConfigFileAndSetRootDir (E:\projects\github\wtto00\android-tools\node_modules\.pnpm\[email protected]_@[email protected][email protected]_@[email protected][email protected]_\node_modules\jest-config\build\readConfigFileAndSetRootDir.js:116:13)
at async readInitialOptions (E:\projects\github\wtto00\android-tools\node_modules\.pnpm\[email protected]_@[email protected][email protected]_@[email protected][email protected]_\node_modules\jest-config\build\index.js:403:13)
at async readConfig (E:\projects\github\wtto00\android-tools\node_modules\.pnpm\[email protected]_@[email protected][email protected]_@[email protected][email protected]_\node_modules\jest-config\build\index.js:147:48)
at async readConfigs (E:\projects\github\wtto00\android-tools\node_modules\.pnpm\[email protected]_@[email protected][email protected]_@[email protected][email protected]_\node_modules\jest-config\build\index.js:424:26)
at async runCLI (E:\projects\github\wtto00\android-tools\node_modules\.pnpm\@[email protected][email protected]_@[email protected][email protected]_\node_modules\@jest\core\build\cli\index.js:151:59)
at async Object.run (E:\projects\github\wtto00\android-tools\node_modules\.pnpm\[email protected]_@[email protected][email protected]_@[email protected][email protected]_\node_modules\jest-cli\build\run.js:130:37)
Additional context
Related dependency versions:
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
Environment
System:
OS: Windows 11 10.0.22631
CPU: (6) x64 Intel(R) Core(TM) i5-9600K CPU @ 3.70GHz
Binaries:
Node: 20.13.1 - ~\AppData\Local\fnm_multishells\11248_1726675469235\node.EXE
npm: 10.8.1 - ~\AppData\Local\fnm_multishells\11248_1726675469235\npm.CMD
pnpm: 9.1.1 - ~\AppData\Local\fnm_multishells\11248_1726675469235\pnpm.CMD
npmPackages:
jest: ^29.7.0 => 29.7.0