@Before public final void before() { if (suppressOutputStreams) { prevSysOut = System.out; prevSysErr = System.err; try { sysout = new ByteArrayOutputStream(); System.setOut(new PrintStream(sysout, true, IOUtils.UTF_8)); syserr = new ByteArrayOutputStream(); System.setErr(new PrintStream(syserr, true, IOUtils.UTF_8)); } catch (UnsupportedEncodingException e) { throw new RuntimeException(e); } } FailureMarker.resetFailures(); System.setProperty(TestRuleIgnoreTestSuites.PROPERTY_RUN_NESTED, "true"); }
@Before public final void before() { if (suppressOutputStreams) { prevSysOut = System.out; prevSysErr = System.err; try { sysout = new ByteArrayOutputStream(); System.setOut(new PrintStream(sysout, true, "UTF-8")); syserr = new ByteArrayOutputStream(); System.setErr(new PrintStream(syserr, true, "UTF-8")); } catch (UnsupportedEncodingException e) { throw new RuntimeException(e); } } System.setProperty(TestRuleIgnoreTestSuites.PROPERTY_RUN_NESTED, "true"); }
protected static boolean isRunningNested() { return TestRuleIgnoreTestSuites.isRunningNested(); }