From e569eaa8a664b5cee52e11063bfea115229c1ea9 Mon Sep 17 00:00:00 2001 From: Alexey Andreev Date: Tue, 15 Oct 2019 11:53:31 +0300 Subject: [PATCH] C: write test error to stderr rather than stdout --- .../src/main/java/org/teavm/junit/TestNativeEntryPoint.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/junit/src/main/java/org/teavm/junit/TestNativeEntryPoint.java b/tools/junit/src/main/java/org/teavm/junit/TestNativeEntryPoint.java index 79c361748..df4086b70 100644 --- a/tools/junit/src/main/java/org/teavm/junit/TestNativeEntryPoint.java +++ b/tools/junit/src/main/java/org/teavm/junit/TestNativeEntryPoint.java @@ -16,6 +16,7 @@ package org.teavm.junit; import java.io.PrintStream; +import org.teavm.classlib.impl.console.StderrOutputStream; import org.teavm.classlib.impl.console.StdoutOutputStream; final class TestNativeEntryPoint { @@ -27,7 +28,7 @@ final class TestNativeEntryPoint { TestEntryPoint.run(); new PrintStream(StdoutOutputStream.INSTANCE).println("SUCCESS"); } catch (Throwable e) { - PrintStream out = new PrintStream(StdoutOutputStream.INSTANCE); + PrintStream out = new PrintStream(StderrOutputStream.INSTANCE); e.printStackTrace(out); out.println("FAILURE"); }