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

facts don't catch exceptions that were outside of an => expression #302

Open
pokle opened this issue Nov 11, 2014 · 4 comments
Open

facts don't catch exceptions that were outside of an => expression #302

pokle opened this issue Nov 11, 2014 · 4 comments

Comments

@pokle
Copy link

pokle commented Nov 11, 2014

We've had a few test failures recently that have resulted in exception traces, but none of the usual Midje failure messages. That makes it a bit hard to know which fact the error was in.

For example:

(fact "you never see this message" (/ 1 0))

results in a stack trace in your terminal, but you never see the "you never see this message" message. That makes it a little bit harder to read.

This is important for us because we do a bit of preparation in a let form before the actual assertions. And if there are any errors in the let block, you never see which form the error was in...

(fact "blah" (let [something (get-something)] something => nil?))    
@marick
Copy link
Owner

marick commented Nov 28, 2014

Added to trello board https://trello.com/b/seyCqTK9/midje

@vincentbernat
Copy link

@pokle I am also a bit annoyed with that. Did you find a workaround?

@pokle
Copy link
Author

pokle commented Nov 18, 2015

@vincentbernat Sorry I don't know of a workaround.

@marick
Copy link
Owner

marick commented Dec 13, 2015

If fixing this, don't forget to note the (now-closed) #336

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants