Skip to content

Commit

Permalink
Add test for when boundaries are disabled.
Browse files Browse the repository at this point in the history
  • Loading branch information
twiecki committed Dec 23, 2020
1 parent 62db6d1 commit 8af44f2
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions pymc3/tests/test_dist_math.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,13 @@ def test_bound():
assert np.prod(bound(logp, cond).eval()) == -np.inf


def test_bound_disabled():
with pm.Model(disable_bounds_check=True):
logp = tt.ones(3)
cond = np.array([1, 0, 1])
assert np.all(bound(logp, cond).eval() == logp.eval())


def test_alltrue_scalar():
assert alltrue_scalar([]).eval()
assert alltrue_scalar([True]).eval()
Expand Down

0 comments on commit 8af44f2

Please sign in to comment.