@Test
public void testDoubleInputLinewise() throws IOException {

	try {
		final String fileContent = "1.21\n2.23\n";
		final FileInputSplit split = createInputSplit(fileContent);
		final PrimitiveInputFormat<Double> format = new PrimitiveInputFormat<Double>(PATH, Double.class);
		format.configure(new Configuration());
		format.open(split);
		Double result = null;
		result = format.nextRecord(result);
		assertEquals(Double.valueOf(1.21), result);
		result = format.nextRecord(result);
		assertEquals(Double.valueOf(2.23), result);
		result = format.nextRecord(result);
		assertNull(result);
		assertTrue(format.reachedEnd());
	}
	catch (Exception ex) {
		fail("Test failed due to a " + ex.getClass().getName() + ": " + ex.getMessage());
	}
}