

def test_warp_no_reproject_dimensions(runner, tmpdir):
    srcname = 'tests/data/shade.tif'
    outputname = str(tmpdir.join('test.tif'))
    result = runner.invoke(warp.warp, [srcname, outputname, '--dimensions', '100', '100'])
    assert (result.exit_code == 0)
    assert os.path.exists(outputname)
    with rasterio.open(srcname) as src:
        with rasterio.open(result) as output:
            assert (output.crs == src.crs)
            assert (output.width == 100)
            assert (output.height == 100)
            assert numpy.allclose([97.839396, 97.839396], [output.affine.a, (- output.affine.e)])

dataset/ETHPy150Open mapbox/rasterio/tests/test_rio_warp.py test_warp_no_reproject_dimensions/VarMisuse@87/126 `outputname`->`result`