QuickCheck for Javascript

Is there a version of quickcheck that works for Javascript and is it well supported? I found several such as check.js and claire, but none of them seem to support reducing unsuccessful test cases, which has always amazed me as the most useful part of the whole problem.

+8
javascript quickcheck
source share
3 answers

I am the creator of jsverify . I will try my best, bug reports and feature requests are welcome.

Readme also has a list of other javascript generating test libraries. So far, I have not found any other good alternative to jsverify.

+8
source share

I wrote quick_check.js , which has a good generator library. There are no reductions yet, but planned.

+3
source share

In javascript, there seems to be a lack of good tools like quickcheck-style validation. However, they are best supported in typed languages, and you can actually write your tests in one of these languages ​​if you want.

To avoid interacting with runtime interop, I would recommend using a language that compiles in JS and runs on node.js (for example: Purescript with purescript-quickcheck ) or a Java-based language using the Nashorn engine provided in Java 8, for example ScalaCheck . You can even use ghcjs and the original flavor of the quickcheck library!

0
source share

All Articles