@Test public void canParseSample(){ RunTest(getSample()); log(project); assertProjectCreated(project, 4, 6); Row row = project.rows.get(0); Assert.assertNotNull(row); Assert.assertNotNull(row.getCell(1)); Assert.assertEquals(row.getCell(1).value, "Author 1, The"); }
@Test public void testCanParseLineBreak(){ RunTest(getSampleWithLineBreak()); log(project); assertProjectCreated(project, 4, 6); Row row = project.rows.get(3); Assert.assertNotNull(row); Assert.assertEquals(row.cells.size(), 4); Assert.assertNotNull(row.getCell(1)); Assert.assertEquals(row.getCell(1).value, "With line\n break"); }
@Test public void canParseSampleWithDuplicateNestedElements(){ RunTest(getSampleWithDuplicateNestedElements()); log(project); assertProjectCreated(project, 4, 12); Row row = project.rows.get(0); Assert.assertNotNull(row); Assert.assertEquals(row.cells.size(), 4); Assert.assertNotNull(row.getCell(1)); Assert.assertEquals(row.getCell(1).value, "Author 1, The"); Assert.assertEquals(project.rows.get(1).getCell(1).value, "Author 1, Another"); }