From 63fb65eb1b30cc1c64552f2175aadde7d96816b4 Mon Sep 17 00:00:00 2001 From: Andreas Beeker Date: Sun, 13 Oct 2019 09:08:24 +0000 Subject: [PATCH] Fix line.separator issues git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1868384 13f79535-47bb-0310-9956-ffa450edef68 --- src/testcases/org/apache/poi/ddf/TestEscherBoolProperty.java | 1 + .../org/apache/poi/ddf/TestEscherChildAnchorRecord.java | 1 + .../org/apache/poi/ddf/TestEscherClientAnchorRecord.java | 1 + src/testcases/org/apache/poi/ddf/TestEscherClientDataRecord.java | 1 + src/testcases/org/apache/poi/ddf/TestEscherDgRecord.java | 1 + src/testcases/org/apache/poi/ddf/TestEscherDggRecord.java | 1 + src/testcases/org/apache/poi/ddf/TestEscherSpRecord.java | 1 + src/testcases/org/apache/poi/ddf/TestEscherSpgrRecord.java | 1 + .../org/apache/poi/ddf/TestEscherSplitMenuColorsRecord.java | 1 + src/testcases/org/apache/poi/ddf/TestUnknownEscherRecord.java | 1 + 10 files changed, 10 insertions(+) diff --git a/src/testcases/org/apache/poi/ddf/TestEscherBoolProperty.java b/src/testcases/org/apache/poi/ddf/TestEscherBoolProperty.java index 339f7e7894..5aa14bf391 100644 --- a/src/testcases/org/apache/poi/ddf/TestEscherBoolProperty.java +++ b/src/testcases/org/apache/poi/ddf/TestEscherBoolProperty.java @@ -34,6 +34,7 @@ public final class TestEscherBoolProperty { "\t, flags: 0x17f /* */ \n" + "\t, value: 1\n" + "}"; + expected = expected.replace("\n", System.getProperty("line.separator")); assertEquals(expected, p.toString()); } } diff --git a/src/testcases/org/apache/poi/ddf/TestEscherChildAnchorRecord.java b/src/testcases/org/apache/poi/ddf/TestEscherChildAnchorRecord.java index 39d88a3c2d..5278ce990c 100644 --- a/src/testcases/org/apache/poi/ddf/TestEscherChildAnchorRecord.java +++ b/src/testcases/org/apache/poi/ddf/TestEscherChildAnchorRecord.java @@ -76,6 +76,7 @@ public final class TestEscherChildAnchorRecord { "\t, x2: 3\n" + "\t, y2: 4\n" + "}"; + expected = expected.replace("\n", System.getProperty("line.separator")); assertEquals( expected, createRecord().toString() ); } diff --git a/src/testcases/org/apache/poi/ddf/TestEscherClientAnchorRecord.java b/src/testcases/org/apache/poi/ddf/TestEscherClientAnchorRecord.java index f2ea01fe83..64d0a6fd8f 100644 --- a/src/testcases/org/apache/poi/ddf/TestEscherClientAnchorRecord.java +++ b/src/testcases/org/apache/poi/ddf/TestEscherClientAnchorRecord.java @@ -88,6 +88,7 @@ public class TestEscherClientAnchorRecord { "\t, dy2: 66 /* 0x0042 */\n" + "\t, remainingData: \"/90=\"\n" + "}"; + expected = expected.replace("\n", System.getProperty("line.separator")); assertEquals( expected, createRecord().toString() ); } diff --git a/src/testcases/org/apache/poi/ddf/TestEscherClientDataRecord.java b/src/testcases/org/apache/poi/ddf/TestEscherClientDataRecord.java index 106d098019..63b21b89f4 100644 --- a/src/testcases/org/apache/poi/ddf/TestEscherClientDataRecord.java +++ b/src/testcases/org/apache/poi/ddf/TestEscherClientDataRecord.java @@ -62,6 +62,7 @@ public class TestEscherClientDataRecord { "\t, recordSize: 8\n" + "\t, remainingData: \"\"\n" + "}"; + expected = expected.replace("\n", System.getProperty("line.separator")); assertEquals( expected, createRecord().toString() ); } diff --git a/src/testcases/org/apache/poi/ddf/TestEscherDgRecord.java b/src/testcases/org/apache/poi/ddf/TestEscherDgRecord.java index 246a895b16..ac7f4bf0f2 100644 --- a/src/testcases/org/apache/poi/ddf/TestEscherDgRecord.java +++ b/src/testcases/org/apache/poi/ddf/TestEscherDgRecord.java @@ -68,6 +68,7 @@ public final class TestEscherDgRecord { "\t, lastMSOSPID: 1025 /* 0x00000401 */\n" + "\t, drawingGroupId: 1\n" + "}"; + expected = expected.replace("\n", System.getProperty("line.separator")); assertEquals( expected, createRecord().toString() ); } diff --git a/src/testcases/org/apache/poi/ddf/TestEscherDggRecord.java b/src/testcases/org/apache/poi/ddf/TestEscherDggRecord.java index ed3b70c1ba..bcd5025c84 100644 --- a/src/testcases/org/apache/poi/ddf/TestEscherDggRecord.java +++ b/src/testcases/org/apache/poi/ddf/TestEscherDggRecord.java @@ -86,6 +86,7 @@ public final class TestEscherDggRecord { "\t, numShapesSaved: 2\n" + "\t, drawingsSaved: 1\n" + "}"; + expected = expected.replace("\n", System.getProperty("line.separator")); assertEquals( expected, createRecord().toString() ); } diff --git a/src/testcases/org/apache/poi/ddf/TestEscherSpRecord.java b/src/testcases/org/apache/poi/ddf/TestEscherSpRecord.java index 241a09dfd1..099022877f 100644 --- a/src/testcases/org/apache/poi/ddf/TestEscherSpRecord.java +++ b/src/testcases/org/apache/poi/ddf/TestEscherSpRecord.java @@ -68,6 +68,7 @@ public class TestEscherSpRecord { "\t, shapeId: 1024 /* 0x00000400 */\n" + "\t, flags: 0x5 /* GROUP | PATRIARCH */ \n" + "}"; + expected = expected.replace("\n", System.getProperty("line.separator")); assertEquals( expected, createRecord().toString() ); } diff --git a/src/testcases/org/apache/poi/ddf/TestEscherSpgrRecord.java b/src/testcases/org/apache/poi/ddf/TestEscherSpgrRecord.java index 6f414f1d6d..6c04df66ec 100644 --- a/src/testcases/org/apache/poi/ddf/TestEscherSpgrRecord.java +++ b/src/testcases/org/apache/poi/ddf/TestEscherSpgrRecord.java @@ -75,6 +75,7 @@ public final class TestEscherSpgrRecord { "\t, rectX2: 3\n" + "\t, rectY2: 4\n" + "}"; + expected = expected.replace("\n", System.getProperty("line.separator")); assertEquals( expected, createRecord().toString() ); } diff --git a/src/testcases/org/apache/poi/ddf/TestEscherSplitMenuColorsRecord.java b/src/testcases/org/apache/poi/ddf/TestEscherSplitMenuColorsRecord.java index 9ac3c5d403..7571dcd6fe 100644 --- a/src/testcases/org/apache/poi/ddf/TestEscherSplitMenuColorsRecord.java +++ b/src/testcases/org/apache/poi/ddf/TestEscherSplitMenuColorsRecord.java @@ -75,6 +75,7 @@ public final class TestEscherSplitMenuColorsRecord { "\t, color3: 2\n" + "\t, color4: 1\n" + "}"; + expected = expected.replace("\n", System.getProperty("line.separator")); assertEquals( expected, createRecord().toString() ); } diff --git a/src/testcases/org/apache/poi/ddf/TestUnknownEscherRecord.java b/src/testcases/org/apache/poi/ddf/TestUnknownEscherRecord.java index 3ee6f9feb3..5a9c1aa459 100644 --- a/src/testcases/org/apache/poi/ddf/TestUnknownEscherRecord.java +++ b/src/testcases/org/apache/poi/ddf/TestUnknownEscherRecord.java @@ -159,6 +159,7 @@ public final class TestUnknownEscherRecord { "\t, recordSize: 8\n" + "\t, data: \"\"\n" + "}"; + expected = expected.replace("\n", System.getProperty("line.separator")); assertEquals(expected, r.toString() ); } }