OpenMC/tests/unit_tests/__init__.py
2018-02-05 07:35:48 -06:00

9 lines
259 B
Python

import numpy as np
import pytest
def assert_unbounded(obj):
"""Assert that a region/cell is unbounded."""
ll, ur = obj.bounding_box
assert ll == pytest.approx((-np.inf, -np.inf, -np.inf))
assert ur == pytest.approx((np.inf, np.inf, np.inf))