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

Throw an Error instead of a string when there's a contract violation #65

Conversation

malcolmredheron
Copy link
Contributor

Change the default to throw an Error when there's a contact violation

As described in #59, this means that we get stack traces in testing environments when preludeTsContractViolationCb is called.

JS has deprecated throwing strings and many (all?) testing environments don't produce stack traces for thrown strings.
@malcolmredheron
Copy link
Contributor Author

BTW, I ran npm run test manually and everything passed.

@emmanueltouzery emmanueltouzery merged commit 2e032d8 into emmanueltouzery:master Sep 26, 2022
@emmanueltouzery
Copy link
Owner

thank you! previously i picked "rebase and merge" i think.
this time "squash and merge"... just FYI.

@malcolmredheron
Copy link
Contributor Author

malcolmredheron commented Sep 26, 2022 via email

@emmanueltouzery
Copy link
Owner

with an extra merge commit? sure, if it offers me i'll do it.

@malcolmredheron
Copy link
Contributor Author

malcolmredheron commented Sep 26, 2022 via email

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.

2 participants