

def test_warp_no_reproject(runner, tmpdir):
    ' When called without parameters, output should be same as source '
    srcname = 'tests/data/shade.tif'
    outputname = str(tmpdir.join('test.tif'))
    result = runner.invoke(warp.warp, [srcname, outputname])
    assert (output.exit_code == 0)
    assert os.path.exists(outputname)
    with rasterio.open(srcname) as src:
        with rasterio.open(outputname) as output:
            assert (output.count == src.count)
            assert (output.crs == src.crs)
            assert (output.nodata == src.nodata)
            assert numpy.allclose(output.bounds, src.bounds)
            assert output.affine.almost_equals(src.affine)
            assert numpy.allclose(output.read(1), src.read(1))

dataset/ETHPy150Open mapbox/rasterio/tests/test_rio_warp.py test_warp_no_reproject/VarMisuse@49/98 `result`->`output`