31
31
from rioxarray .rioxarray import _generate_spatial_coords , _make_coords
32
32
from test .conftest import (
33
33
GDAL_GE_361 ,
34
+ RASTERIO_GE_14 ,
34
35
TEST_COMPARE_DATA_DIR ,
35
36
TEST_INPUT_DATA_DIR ,
36
37
_assert_xarrays_equal ,
@@ -805,7 +806,7 @@ def test_reproject_match__non_geospatial(dummy_dataset_non_geospatial):
805
806
def test_reproject_match__geographic_dataset ():
806
807
lat = [0.1 , 0.15 , 0.2 ]
807
808
lon = [0.1 , 0.15 , 0.2 ]
808
- data = numpy .arange (1 , 10 ).reshape (3 , 3 )
809
+ data = numpy .arange (1 , 10 , dtype = numpy . float32 ).reshape (3 , 3 )
809
810
ds = xarray .Dataset (
810
811
data_vars = {
811
812
"foo" : (["lat" , "lon" ], data ),
@@ -2185,7 +2186,7 @@ def test_reproject_transform_missing_shape():
2185
2186
"dtype, expected_nodata" ,
2186
2187
[
2187
2188
(numpy .uint8 , 255 ),
2188
- (numpy .int8 , - 128 ),
2189
+ pytest . param (numpy .int8 , - 128 , marks = pytest . mark . xfail ( not RASTERIO_GE_14 ) ),
2189
2190
(numpy .uint16 , 65535 ),
2190
2191
(numpy .int16 , - 32768 ),
2191
2192
(numpy .uint32 , 4294967295 ),
@@ -2194,8 +2195,16 @@ def test_reproject_transform_missing_shape():
2194
2195
(numpy .float64 , numpy .nan ),
2195
2196
(numpy .complex64 , numpy .nan ),
2196
2197
(numpy .complex128 , numpy .nan ),
2197
- (numpy .uint64 , 18446744073709551615 ),
2198
- (numpy .int64 , - 9223372036854775808 ),
2198
+ pytest .param (
2199
+ numpy .uint64 ,
2200
+ 18446744073709551615 ,
2201
+ marks = pytest .mark .xfail (not RASTERIO_GE_14 ),
2202
+ ),
2203
+ pytest .param (
2204
+ numpy .int64 ,
2205
+ - 9223372036854775808 ,
2206
+ marks = pytest .mark .xfail (not RASTERIO_GE_14 ),
2207
+ ),
2199
2208
],
2200
2209
)
2201
2210
def test_reproject_default_nodata (dtype , expected_nodata ):
0 commit comments