Skip to content

Commit

Permalink
test(distance_to_anomaly): test criteria data check
Browse files Browse the repository at this point in the history
  • Loading branch information
nialov committed Mar 15, 2024
1 parent 74cc1da commit fea0258
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion tests/raster_processing/test_distance_to_anomaly.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
import rasterio.profiles
from beartype.roar import BeartypeCallHintParamViolation

from eis_toolkit.exceptions import InvalidParameterValueException
from eis_toolkit.exceptions import EmptyDataException, InvalidParameterValueException
from eis_toolkit.raster_processing import distance_to_anomaly
from tests.raster_processing.clip_test import raster_path as SMALL_RASTER_PATH

Expand Down Expand Up @@ -228,6 +228,15 @@ def test_distance_to_anomaly_gdal(
partial(pytest.raises, BeartypeCallHintParamViolation),
id="expected_invalid_param_due_to_tuple_of_length_three",
),
pytest.param(
SMALL_RASTER_PROFILE,
SMALL_RASTER_DATA,
(100.5, 122.5),
"in_between",
dict,
partial(pytest.raises, EmptyDataException),
id="expected_empty_data_due_to_threshold_range_outside_values",
),
],
)
def test_distance_to_anomaly_check(
Expand Down

0 comments on commit fea0258

Please sign in to comment.