@Test
public void testReadFeaturesFromInvalidFile() throws
                                              Exception {

    // given a wrong file to read
    final File wkt = getFixtureAsFile("featurestyle.json");
    // when trying to parse this wrong file as WKT
    new WKTFileReader().readFeatures(wkt,
                                     onWKTFileReaderListener);
    // then
    verify(onWKTFileReaderListener).onStart(anyInt());
    verify(onWKTFileReaderListener,
           never()).onProgress(anyInt(),
                               anyInt(),
                               any(Feature.class));
    verify(onWKTFileReaderListener).onFinish(featureCollectionArgumentCaptor.capture());
    final FeatureCollection featureCollection = featureCollectionArgumentCaptor.getValue();
    assertNotNull(featureCollection);
    assertTrue(featureCollection.isEmpty());
}