@Test
public void testParsingEnglishSample() throws IOException {
ObjectStream<NameSample> sampleStream = openData(LANGUAGE.EN, ENGLISH_SAMPLE);
NameSample personName = sampleStream.read();
assertNotNull(personName);
assertEquals(9, personName.getSentence().length);
assertEquals(0, personName.getNames().length);
assertEquals(true, personName.isClearAdaptiveDataSet());
personName = sampleStream.read();
assertNotNull(personName);
assertEquals(2, personName.getSentence().length);
assertEquals(1, personName.getNames().length);
assertEquals(false, personName.isClearAdaptiveDataSet());
Span nameSpan = personName.getNames()[0];
assertEquals(0, nameSpan.getStart());
assertEquals(2, nameSpan.getEnd());
assertNull(sampleStream.read());
}