probcomp / metaprob

An embedded language for probabilistic programming and meta-programming.
GNU General Public License v3.0
168 stars 17 forks source link

Add test verifying metaprob.examples.all can be required #75

Closed zane closed 5 years ago

zane commented 6 years ago

What does this do?

Replaces the dummy function foo in metaprob.examples.all-test with a test that explicitly verifies that metaprob.examples.all can be required.

Fixes #67.

Why should we do this?

See the discussion in #67.

How do I test this?

First run the new test and watch it pass:

clojure -Atest -n metaprob.examples.all-test

Then add a line to metaprob.examples.all that, when evaluated, will trigger an exception. For example:

(define foo (/ 1 0))

Now run the new test again and watch it fail.

jar398 commented 5 years ago

I've looked at this and it seems a no brainer. +1 to merge.