Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make seed and path copy pasteable #140

Merged
merged 1 commit into from
Jul 2, 2018

Conversation

paldepind
Copy link
Contributor

This PR changes the error message on a failed test slightly. It looks like this:

Property failed after 1 tests
{ seed: 1530466923032, path: "1:1:0:0:0:0:0:0:1:1:3:8:8:9:11:16:20:19:19:19:19:19:22:23" }
Counterexample: [[32,32738,34]]
Shrunk 0 time(s)

The major change is that the seed and the path is now printed so that they can be easily copy-pasted into one's code as an argument to assert. Additionally, the counterexample is prefixed with the text "Counterexample" to make it easier to understand and distinguish.

@dubzzz
Copy link
Owner

dubzzz commented Jul 2, 2018

Very good idea 💡

Seems like prettier is complying: you should run npm run format:fix

@paldepind paldepind force-pushed the copy-pasteable-seed branch from 213dc91 to 4b88a84 Compare July 2, 2018 06:22
@paldepind
Copy link
Contributor Author

Thank you.

I've fixed the formatting. I didn't notice Prettier was being used since the lines were so long 😅

@dubzzz
Copy link
Owner

dubzzz commented Jul 2, 2018

There is one last issue in test/e2e. You can start them by using npm run e2e.

The test is:

Shadows (seed: 1530512859038)
    1) Should detect an implementation issue

This test suite - e2e - is used to confirm that the framework is able to do what it says from an user point of view:

  • shrink on the minimal entry
  • be biased enough to discover issues
  • replay...

It runs end-to-end tests on the framework.

@paldepind paldepind force-pushed the copy-pasteable-seed branch from 4b88a84 to 438c5f4 Compare July 2, 2018 10:20
@coveralls
Copy link

coveralls commented Jul 2, 2018

Coverage Status

Coverage increased (+0.3%) to 92.369% when pulling 438c5f4 on paldepind:copy-pasteable-seed into 38b0c46 on dubzzz:master.

@paldepind
Copy link
Contributor Author

Ah. I was only running npm test. Travis is happy now 😄

@dubzzz dubzzz merged commit 3d52506 into dubzzz:master Jul 2, 2018
@dubzzz
Copy link
Owner

dubzzz commented Jul 2, 2018

Merged, thanks for the contribution ;)
Please add yourself in the contributors file

@paldepind paldepind deleted the copy-pasteable-seed branch July 2, 2018 13:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants