Commit 807181c5 authored by Eric Bruneton's avatar Eric Bruneton
Browse files

Make asm util tests independent of System.lineSeparator().

parent d43e664d
......@@ -66,7 +66,7 @@ class ASMifierTest extends AsmTest {
private static final String EXPECTED_USAGE =
"Prints the ASM code to generate the given class.\n"
+ "Usage: ASMifier [-nodebug] <fully qualified class name or class file name>\n";
+ "Usage: ASMifier [-nodebug] <fully qualified class name or class file name>";
private static final IClassLoader ICLASS_LOADER =
new ClassLoaderIClassLoader(new URLClassLoader(new URL[0]));
......@@ -126,7 +126,7 @@ class ASMifierTest extends AsmTest {
ASMifier.main(args, new PrintWriter(output, true), new PrintWriter(logger, true));
assertEquals("", output.toString());
assertEquals(EXPECTED_USAGE, logger.toString());
assertEquals(EXPECTED_USAGE, logger.toString().trim());
}
@Test
......@@ -138,7 +138,7 @@ class ASMifierTest extends AsmTest {
ASMifier.main(args, new PrintWriter(output, true), new PrintWriter(logger, true));
assertEquals("", output.toString());
assertEquals(EXPECTED_USAGE, logger.toString());
assertEquals(EXPECTED_USAGE, logger.toString().trim());
}
@Test
......@@ -150,7 +150,7 @@ class ASMifierTest extends AsmTest {
ASMifier.main(args, new PrintWriter(output, true), new PrintWriter(logger, true));
assertEquals("", output.toString());
assertEquals(EXPECTED_USAGE, logger.toString());
assertEquals(EXPECTED_USAGE, logger.toString().trim());
}
@Test
......
......@@ -59,7 +59,7 @@ class CheckClassAdapterTest extends AsmTest implements Opcodes {
private static final String EXPECTED_USAGE =
"Verifies the given class.\n"
+ "Usage: CheckClassAdapter <fully qualified class name or class file name>\n";
+ "Usage: CheckClassAdapter <fully qualified class name or class file name>";
@Test
void testConstructor() {
......@@ -505,7 +505,7 @@ class CheckClassAdapterTest extends AsmTest implements Opcodes {
CheckClassAdapter.main(args, new PrintWriter(logger, true));
assertEquals(EXPECTED_USAGE, logger.toString());
assertEquals(EXPECTED_USAGE, logger.toString().trim());
}
@Test
......@@ -515,7 +515,7 @@ class CheckClassAdapterTest extends AsmTest implements Opcodes {
CheckClassAdapter.main(args, new PrintWriter(logger, true));
assertEquals(EXPECTED_USAGE, logger.toString());
assertEquals(EXPECTED_USAGE, logger.toString().trim());
}
@Test
......
......@@ -57,7 +57,7 @@ class TextifierTest extends AsmTest {
private static final String EXPECTED_USAGE =
"Prints a disassembled view of the given class.\n"
+ "Usage: Textifier [-nodebug] <fully qualified class name or class file name>\n";
+ "Usage: Textifier [-nodebug] <fully qualified class name or class file name>";
@Test
void testConstructor() {
......@@ -103,7 +103,7 @@ class TextifierTest extends AsmTest {
Textifier.main(args, new PrintWriter(output, true), new PrintWriter(logger, true));
assertEquals("", output.toString());
assertEquals(EXPECTED_USAGE, logger.toString());
assertEquals(EXPECTED_USAGE, logger.toString().trim());
}
@Test
......@@ -115,7 +115,7 @@ class TextifierTest extends AsmTest {
Textifier.main(args, new PrintWriter(output, true), new PrintWriter(logger, true));
assertEquals("", output.toString());
assertEquals(EXPECTED_USAGE, logger.toString());
assertEquals(EXPECTED_USAGE, logger.toString().trim());
}
@Test
......@@ -127,7 +127,7 @@ class TextifierTest extends AsmTest {
Textifier.main(args, new PrintWriter(output, true), new PrintWriter(logger, true));
assertEquals("", output.toString());
assertEquals(EXPECTED_USAGE, logger.toString());
assertEquals(EXPECTED_USAGE, logger.toString().trim());
}
@Test
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment