@Test public void tests() throws SuiteException { final SunshineTest.Fake test = new SunshineTest.Fake(); MatcherAssert.assertThat( new SunshineSuitePrintable(new SunshineSuite.Fake(test)).tests(), Matchers.contains(test)); }
@Override public final List<SunshineTest> tests() throws SuiteException { final List<SunshineTest> tests = this.sunshineSuite.tests(); final StringBuilder message = new StringBuilder(); message.append("Sunshine found ") .append(tests.size()) .append( " classes by the specified pattern. They all will be passed to appropriate xUnit engine.") .append("\nClasses:"); tests.forEach(c -> message.append("\n- ").append(c)); System.out.println(message); return tests; }
SunshineSuitePrintable implements SunshineSuite { @Override public final List<SunshineTest> tests() throws SuiteException { final List<SunshineTest> tests = this.sunshineSuite.tests(); final StringBuilder message = new StringBuilder(); message.append("Sunshine found ") .append(tests.size()) .append( " classes by the specified pattern. They all will be passed to appropriate xUnit engine.") .append("\nClasses:"); tests.forEach(c -> message.append("\n- ").append(c)); System.out.println(message); return tests; } }
SunshineSuitePrintable implements SunshineSuite { @Override public final List<SunshineTest> tests() throws SuiteException { final List<SunshineTest> tests = this.sunshineSuite.tests(); final StringBuilder message = new StringBuilder(); message.append("Sunshine found ") .append(tests.size()) .append( " classes by the specified pattern. They all will be passed to appropriate xUnit engine.") .append("\nClasses:"); tests.forEach(c -> message.append("\n- ").append(c)); System.out.println(message); return tests; } SunshineSuitePrintable(SunshineSuite sunshineSuite); }
SunshineSuitePrintable implements SunshineSuite { @Override public final List<SunshineTest> tests() throws SuiteException { final List<SunshineTest> tests = this.sunshineSuite.tests(); final StringBuilder message = new StringBuilder(); message.append("Sunshine found ") .append(tests.size()) .append( " classes by the specified pattern. They all will be passed to appropriate xUnit engine.") .append("\nClasses:"); tests.forEach(c -> message.append("\n- ").append(c)); System.out.println(message); return tests; } SunshineSuitePrintable(SunshineSuite sunshineSuite); @Override final List<SunshineTest> tests(); }
SunshineSuitePrintable implements SunshineSuite { @Override public final List<SunshineTest> tests() throws SuiteException { final List<SunshineTest> tests = this.sunshineSuite.tests(); final StringBuilder message = new StringBuilder(); message.append("Sunshine found ") .append(tests.size()) .append( " classes by the specified pattern. They all will be passed to appropriate xUnit engine.") .append("\nClasses:"); tests.forEach(c -> message.append("\n- ").append(c)); System.out.println(message); return tests; } SunshineSuitePrintable(SunshineSuite sunshineSuite); @Override final List<SunshineTest> tests();  }