mpizenberg / elm-test-rs

Fast and portable executable to run your Elm tests
BSD 3-Clause "New" or "Revised" License
80 stars 13 forks source link

Edge case for --fuzz 0 #74

Closed mpizenberg closed 3 years ago

mpizenberg commented 3 years ago

Reported by lydell.

This is a super edge case:

❯ ~/elm-test-rs --fuzz 0

elm-test-rs 1.0.0-beta for elm 0.19.1
--------------------------------

✓ Compilation of tests modules succeeded
No exposed values of type Test was found. Did you forget to expose them?
Your tests are invalid: Test runner run count must be at least 1, not 0
Running duration (since Node.js start): 168 ms

It feels like the “No exposed …“ and “Running duration …“ lines should not be there in this case (only “Your tests are invalid”)

mpizenberg commented 3 years ago

We should validate the integer given as parameter right at the beginning when validating CLI arguments so we can avoid all the following output

mpizenberg commented 3 years ago

Done in 2d9b029