-
Notifications
You must be signed in to change notification settings - Fork 24
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
Exception no longer mentions source? (:args, :ret) #51
Comments
Hey! Thanks for using Orchestra. The information is available, if we look into the exception data thrown. Here is the exception data from Orchestra's own test suite. Failure in return check{:clojure.spec.alpha/problems [{:path []
:pred clojure.core/integer?
:val true
:via []
:in []}]
:clojure.spec.alpha/spec #object[clojure.spec.alpha$spec_impl$reify__2069 0x5d92bd50 "clojure.spec.alpha$spec_impl$reify__2069@5d92bd50"]
:clojure.spec.alpha/value true
:clojure.spec.alpha/fn orchestra.core-test/ret'
:clojure.spec.alpha/ret true
:clojure.spec.alpha/failure :instrument
:orchestra.spec.test/caller {:file "core_test.cljc"
:line 35
:var-scope orchestra.core-test/fn--21819}} Failure in arg check{:clojure.spec.alpha/problems [{:path [:meow]
:pred clojure.core/string?
:val 42
:via []
:in [0]}]
:clojure.spec.alpha/spec #object[clojure.spec.alpha$regex_spec_impl$reify__2519 0x50a7c4c4 "clojure.spec.alpha$regex_spec_impl$reify__2519@50a7c4c4"]
:clojure.spec.alpha/value (42)
:clojure.spec.alpha/fn orchestra.core-test/args'
:clojure.spec.alpha/args (42)
:clojure.spec.alpha/failure :instrument
:orchestra.spec.test/caller {:file "core_test.cljc"
:line 24
:var-scope orchestra.core-test/fn--30314}} So, if However, while you can use this data, for most people I highly recommend just using Expound to format your spec failures. Orchestra is tested specifically to work with Expound. |
Ah I see, I will give Expound a try. |
Sure thing. Happy hacking. |
I gave Expound a try and IMO it's not as good as handy as the information in the exception message. |
Hm, I see where you're coming from. I would be open to this, if we distinguish:
and if it still works properly with Expound. I'll reopen this ticket to keep this task on the books. |
With the new version there doesn't seem to be a way to know from where the failure originates.
(Bad arguments or bad return value?)
The text was updated successfully, but these errors were encountered: