コード例 #1
0
def test_clip_empty_source(source, empty_source, vals_request):
    clip = raster.Clip(empty_source, raster.Snap(source, empty_source))
    assert clip.get_data(**vals_request) is None
コード例 #2
0
def test_clip_attrs_mask_empty(source, empty_source):
    # clip should propagate the (empty) extent of the clipping mask
    clip = raster.Clip(source, raster.Snap(empty_source, source))
    assert clip.extent is None
    assert clip.geometry is None