예제 #1
0
def test_can_create_osr():
    assert _can_create_osr({'init': 'EPSG:4326'})
    assert _can_create_osr('EPSG:4326')
예제 #2
0
def test_can_create_osr_invalid_epsg_0():
    assert not _can_create_osr('EPSG:')
예제 #3
0
def test_can_create_osr_none_err(arg):
    """Passing None or empty fails"""
    with pytest.raises(ValueError):
        _can_create_osr(arg)
예제 #4
0
def test_can_create_osr():
    assert _can_create_osr({'init': 'EPSG:4326'})
    assert _can_create_osr('EPSG:4326')
예제 #5
0
def test_can_create_osr_invalid(arg):
    """invalid CRS definitions fail"""
    assert not _can_create_osr(arg)
예제 #6
0
def test_can_create_osr_invalid():
    assert not _can_create_osr(None)
    assert not _can_create_osr('EPSG:-1')
    assert not _can_create_osr('EPSG:')
    assert not _can_create_osr('foo')
예제 #7
0
def test_can_create_osr_none_err(arg):
    """Passing None or empty fails"""
    assert not _can_create_osr(arg)
예제 #8
0
파일: test_crs.py 프로젝트: mapbox/rasterio
def test_can_create_osr():
    assert _can_create_osr({'init': 'epsg:4326'})
    assert _can_create_osr('epsg:4326')
예제 #9
0
파일: test_crs.py 프로젝트: mapbox/rasterio
def test_can_create_osr_invalid_epsg_0():
    assert not _can_create_osr('epsg:')
예제 #10
0
def test_can_create_osr_invalid_epsg_0():
    """this invalid CRS should fail, but doesn't because of a GDAL bug"""
    assert not _can_create_osr('EPSG:')
예제 #11
0
파일: test_crs.py 프로젝트: mapbox/rasterio
def test_can_create_osr_none_err(arg):
    """Passing None or empty fails"""
    assert not _can_create_osr(arg)
예제 #12
0
def test_can_create_osr_none_err(arg):
    """Passing None or empty fails"""
    with pytest.raises(ValueError):
        _can_create_osr(arg)
예제 #13
0
def test_can_create_osr_invalid():
    assert not _can_create_osr(None)
    assert not _can_create_osr('EPSG:-1')
    assert not _can_create_osr('EPSG:')
    assert not _can_create_osr('foo')
예제 #14
0
def test_can_create_osr_empty():
    assert _can_create_osr({})
    assert _can_create_osr('')
예제 #15
0
def test_can_create_osr_invalid(arg):
    """invalid CRS definitions fail"""
    assert not _can_create_osr(arg)
예제 #16
0
def test_can_create_osr():
    assert _can_create_osr({'init': 'epsg:4326'})
    assert _can_create_osr('epsg:4326')
예제 #17
0
def test_can_create_osr_invalid_epsg_0():
    """this invalid CRS should fail, but doesn't because of a GDAL bug"""
    assert not _can_create_osr('EPSG:')
예제 #18
0
def test_can_create_osr_empty():
    assert _can_create_osr({})
    assert _can_create_osr('')