changeset 50916:2f9a0c4fcf58

8204355: [Graal] org.graalvm.compiler.debug.test.CSVUtilTest fails on Windows due to improper line separator used Reviewed-by: kvn
author iignatyev
date Fri, 29 Jun 2018 13:44:13 -0700
parents 78711bd05b5a
children 55a43beaa529
files src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug.test/src/org/graalvm/compiler/debug/test/CSVUtilTest.java
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug.test/src/org/graalvm/compiler/debug/test/CSVUtilTest.java	Fri Jun 29 13:44:09 2018 -0700
+++ b/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug.test/src/org/graalvm/compiler/debug/test/CSVUtilTest.java	Fri Jun 29 13:44:13 2018 -0700
@@ -117,8 +117,8 @@
             CSVUtil.Escape.println(new PrintStream(outputStream), format, toObjectArray(args));
             // get the actual string
             String printedStream = new String(outputStream.toByteArray(), StandardCharsets.UTF_8);
-            // remove newline
-            assertEquals(expected, printedStream.substring(0, printedStream.length() - 1));
+            // add newline to the expected string
+            assertEquals(expected + System.lineSeparator(), printedStream);
         }
 
         private static Object[] toObjectArray(String args) {