I am away in holidays and missed your response Brian...Thanks a lot for
taking the time to reply and of course thanks for midje! I will consult the
entire midje wiki once I go back to an actual office!!!

Jim

On Mon, Jun 25, 2012 at 11:05 PM, Brian Marick <mar...@exampler.com> wrote:

>
> On Jun 25, 2012, at 6:21 AM, Jim - FooBar(); wrote:
> > (fact (try (fn-that-throws-exc bad-arg)
> >         (catch Exception e :works)) => :works)
>
> (fact
>  (fn-that-throws-exc bad-arg) => (throws Exception))
>
> You can also check the message, run a predicate over the exception, etc.
>
> https://github.com/marick/Midje/wiki/Checkers
>
> >
> > Ah, ok.  Midje seems to support that, too.  See
> >
> >
> https://github.com/marick/Midje/wiki/Prerequisites-that-throw-exceptions
>
> This is actually for sort of the opposite purpose. You're writing a
> function that needs to be able to handle an exception. That exception is
> hard to generate. So this is a way to artificially create and throw one.
>
>
> -----
> Brian Marick, Artisanal Labrador
> Now working at http://path11.com
> Contract programming in Ruby and Clojure
> Occasional consulting on Agile
>
>
> --
> You received this message because you are subscribed to the Google
> Groups "Clojure" group.
> To post to this group, send email to clojure@googlegroups.com
> Note that posts from new members are moderated - please be patient with
> your first post.
> To unsubscribe from this group, send email to
> clojure+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/clojure?hl=en
>

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Reply via email to