You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The example code works in ReScript 10, and 11, but not 11 with "uncurried": false set. In that mode an unnecessary param argument is emitted for the call to the test external - I've added an exception when this happens, but in rescript-jest this causes jest to think it's an async test and wait for a callback incorrectly.
The workaround is to drop the @uncurry (which I've demonstrated with the _testPass external) and use manual uncurried functions. If you comment out the _testFail call it works in all 3 compilers.
Incidentally I ran in the exact same issue at the exact same time. It causes almost all tests to fail for us, because Jest relies on arity. Repro of the behavior here (I found some variants of this behavior here):
Thank you for filing! Check list:
OS and browser versions, if relevant.not browser specificIs it already fixed in master? InstructionsnoFirst reported in 11.0.0-rc4 glennsl/rescript-jest#119
The example code works in ReScript 10, and 11, but not 11 with
"uncurried": false
set. In that mode an unnecessaryparam
argument is emitted for the call to thetest
external - I've added an exception when this happens, but inrescript-jest
this causesjest
to think it's an async test and wait for a callback incorrectly.The workaround is to drop the
@uncurry
(which I've demonstrated with the_testPass
external) and use manual uncurried functions. If you comment out the_testFail
call it works in all 3 compilers.To me that suggests a bug with
@uncurry
in 11?Example code:
The text was updated successfully, but these errors were encountered: