diff --git a/geoutils/vector.py b/geoutils/vector.py index 1e270be4..f4c61ab8 100644 --- a/geoutils/vector.py +++ b/geoutils/vector.py @@ -1138,7 +1138,7 @@ def reproject( try: ds_ref = Vector(ref) except pyogrio.errors.DataSourceError: - raise ValueError("Could not open raster or vector with rasterio or fiona.") + raise ValueError("Could not open raster or vector with rasterio or pyogrio.") else: raise TypeError("Type of ref must be string path to file, Raster or Vector.") diff --git a/tests/test_vector.py b/tests/test_vector.py index 25d4fbb3..08d848d3 100644 --- a/tests/test_vector.py +++ b/tests/test_vector.py @@ -166,9 +166,7 @@ def test_reproject(self) -> None: with pytest.raises(ValueError, match=re.escape("Reference raster or vector path does not exist.")): v0.reproject(ref="tmp.lol") # If it exists but cannot be opened by rasterio or fiona - with pytest.raises( - ValueError, match=re.escape("'geoutils/examples.py' not recognized as being in a supported file format.") - ): + with pytest.raises(ValueError, match=re.escape("Could not open raster or vector with rasterio or pyogrio.")): v0.reproject(ref="geoutils/examples.py") # If input of wrong type with pytest.raises(TypeError, match=re.escape("Type of ref must be string path to file, Raster or Vector.")):