🐛 Bug Report
Custom transformer receives jest config string via getCacheKey. In ts-jest recently we rely on testRegex to do some logic. However, the value of testRegex which is passed to transformer is unusable. Instead of receiving the real value of the regex, transformer receives it as [{}]
Related to kulshekhar/ts-jest#1509
To Reproduce
Steps to reproduce the behavior:
Expected behavior
testRegex value which is passed to transformer should be usable and retain its original value.
Link to repl or repo (highly encouraged)
https://github.com/ahnpnl/ts-jest-babel-example/tree/test-regex-transformer
envinfo
System:
OS: macOS 10.15.4
CPU: (8) x64 Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz
Binaries:
Node: 12.16.1 - /usr/local/bin/node
Yarn: 1.22.4 - /usr/local/bin/yarn
npm: 6.14.4 - /usr/local/bin/npm
npmPackages:
jest: ^25.2.7 => 25.2.7
🐛 Bug Report
Custom transformer receives jest config string via
getCacheKey. Ints-jestrecently we rely ontestRegexto do some logic. However, the value oftestRegexwhich is passed to transformer is unusable. Instead of receiving the real value of the regex, transformer receives it as[{}]Related to kulshekhar/ts-jest#1509
To Reproduce
Steps to reproduce the behavior:
yarn, runyarn testand see the exceptiongetCacheKeyand inspectjestConfigStr, observe the value in the picture below (red circle)ScriptTransformer.jsconstructor, observe the input value ofconfigis[{}]and it is unusable.Expected behavior
testRegexvalue which is passed to transformer should be usable and retain its original value.Link to repl or repo (highly encouraged)
https://github.com/ahnpnl/ts-jest-babel-example/tree/test-regex-transformer
envinfo