From b4906964dcf175c260dbb38c320a158007b6cd97 Mon Sep 17 00:00:00 2001 From: Paul Rambags Date: Tue, 11 Aug 2020 09:13:13 +0200 Subject: [PATCH] #32: break-before-page-1 --- .../formatter/test/SequenceBreakTest.java | 14 ++++++++++- .../break-before-page-1-expected.pef | 24 +++++++++++++++++++ .../break-before-page-1-input.obfl | 19 +++++++++++++++ .../sequence-break/parsing-expected.pef | 4 +--- .../formatter/impl/sheet/SheetDataSource.java | 7 +++++- 5 files changed, 63 insertions(+), 5 deletions(-) create mode 100644 integrationtest/org/daisy/dotify/formatter/test/resource-files/sequence-break/break-before-page-1-expected.pef create mode 100644 integrationtest/org/daisy/dotify/formatter/test/resource-files/sequence-break/break-before-page-1-input.obfl diff --git a/integrationtest/org/daisy/dotify/formatter/test/SequenceBreakTest.java b/integrationtest/org/daisy/dotify/formatter/test/SequenceBreakTest.java index ccdee291..86882f94 100644 --- a/integrationtest/org/daisy/dotify/formatter/test/SequenceBreakTest.java +++ b/integrationtest/org/daisy/dotify/formatter/test/SequenceBreakTest.java @@ -16,7 +16,7 @@ public class SequenceBreakTest extends AbstractFormatterEngineTest { @Test - public void testParsing() throws + public void parsingTest() throws LayoutEngineException, IOException, PagedMediaWriterConfigurationException { @@ -27,4 +27,16 @@ public void testParsing() throws ); } + @Test + public void breakBeforePage1Test() throws + LayoutEngineException, + IOException, + PagedMediaWriterConfigurationException { + testPEF( + "resource-files/sequence-break/break-before-page-1-input.obfl", + "resource-files/sequence-break/break-before-page-1-expected.pef", + true + ); + } + } diff --git a/integrationtest/org/daisy/dotify/formatter/test/resource-files/sequence-break/break-before-page-1-expected.pef b/integrationtest/org/daisy/dotify/formatter/test/resource-files/sequence-break/break-before-page-1-expected.pef new file mode 100644 index 00000000..7812cdca --- /dev/null +++ b/integrationtest/org/daisy/dotify/formatter/test/resource-files/sequence-break/break-before-page-1-expected.pef @@ -0,0 +1,24 @@ + + + + + application/x-pef+xml + identifier? + 2020-08-10 + break-before="page" (1) + Tests a scenario with two content sequences and the second one has break-before="page" + + + + +
+ + ⠤⠤⠤ + + + ⠤⠤⠤ + +
+
+ +
diff --git a/integrationtest/org/daisy/dotify/formatter/test/resource-files/sequence-break/break-before-page-1-input.obfl b/integrationtest/org/daisy/dotify/formatter/test/resource-files/sequence-break/break-before-page-1-input.obfl new file mode 100644 index 00000000..4e0ab4df --- /dev/null +++ b/integrationtest/org/daisy/dotify/formatter/test/resource-files/sequence-break/break-before-page-1-input.obfl @@ -0,0 +1,19 @@ + + + break-before="page" (1) + Tests a scenario with two content sequences and the + second one has break-before="page" + + + +
+