OfxTransactionReader implements Closeable { String readNextNonBlankLine() throws IOException { skipBlankLines(); return reader.readLine(); } OfxTransactionReader(InputStream inputStream); List<Transaction> transactions(); @Override void close();  }
@Test public void readNextNonBlankLine() throws IOException { try (OfxTransactionReader reader = new OfxTransactionReader( new ByteArrayInputStream("\n\r\none\n\rtwo".getBytes(StandardCharsets.UTF_8)))) { assertEquals("one", reader.readNextNonBlankLine()); assertEquals("two", reader.readNextNonBlankLine()); assertEquals(null, reader.readNextNonBlankLine()); } }