Skip to content

Commit

Permalink
checkout gimli.units raises UdunitsError
Browse files Browse the repository at this point in the history
  • Loading branch information
mcflugen committed Oct 3, 2024
1 parent ce9508f commit 556183d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/framework/test_bmi_var_units.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import numpy as np
import pytest
from gimli import IncompatibleUnitsError, UnitNameError
from gimli._udunits2 import UdunitsError
from numpy.testing import assert_array_equal

from pymt.framework.bmi_bridge import BmiTimeInterpolator, GridMapperMixIn, _BmiCap
Expand Down Expand Up @@ -64,12 +64,12 @@ def test_unit_conversion():
def test_incompatible_units():
"""Test wrapping BMI time methods."""
bmi = Bmi()
with pytest.raises(IncompatibleUnitsError):
with pytest.raises(UdunitsError):
bmi.get_value("elevation", units="kg")


def test_bad_units():
"""Test wrapping BMI time methods."""
bmi = Bmi()
with pytest.raises(UnitNameError):
with pytest.raises(UdunitsError):
bmi.get_value("elevation", units="not_real_units")

0 comments on commit 556183d

Please sign in to comment.