Closed jseminck closed 8 years ago
@jseminck thanks for opening this issue together with the PR describing the problem. It should be fixed in rc6. Could you please let me know if it works for you.
Hi. Thanks for the fast reply. Indeed this seems to work now, but we cannot upgrade due to compatibility issue with `babel-plugin-rewire', see issue https://github.com/speedskater/babel-plugin-rewire/issues/148
Hello,
babel-rewire-plugin mocking fails when the exported function contains another function definition. I will create a PR with a failing test case to investigate, but basically, when trying to mock out the variable
test
using the syntaxfileName.__set__({test: 2000});
for the following file, this error is returned:Error TypeError: _get__(...).set is not a function
File:
However, the following approaches work:
And
Cheers,