@Test
void invalidFile() throws Exception {

    // given
    FileUtils.writeStringToFile(file1, "corrupt", "UTF-8");
    streamFileData1 = new StreamFileData(file1.toString(), new FileInputStream(file1));
    // when
    Assertions.assertThrows(IllegalArgumentException.class, () -> {
        recordFileParser.parse(streamFileData1);
    });
    // then
    verify(recordStreamFileListener).onStart(streamFileData1);
    verify(recordStreamFileListener, never()).onEnd(recordFile1);
    verify(recordStreamFileListener).onError();
}