@Test
public void cloudExtractionTest() throws Exception {

    GeoTiffReader reader = null;
    FeatureIterator<SimpleFeature> iter = null;
    GridCoverage2D cov = null;
    try {
        reader = new GeoTiffReader(cloudFile);
        cov = reader.read(null);
        SimpleFeatureCollection fc = process.execute(cov, null, 10d, false, null, true, true,
                null, null);
        assertEquals(1, fc.size());
        iter = fc.features();
        SimpleFeature feature = iter.next();
        MultiPolygon geometry = (MultiPolygon) feature.getDefaultGeometry();
        assertTrue(referenceGeometry.equalsExact(geometry, TOLERANCE));
    } finally {
        if (iter != null) {
            iter.close();
        }
        if (reader != null) {
            try {
                reader.dispose();
            } catch (Throwable t) {
            }
        }
        if (cov != null) {
            try {
                cov.dispose(true);
            } catch (Throwable t) {
            }
        }
    }
}