Update to match checkStyle rules added for test packages #324

This commit is contained in:
Joseph McCarthy 2015-12-29 22:07:52 +00:00
parent 52192de909
commit 17b889c31d
2 changed files with 26 additions and 26 deletions

View File

@ -4,10 +4,10 @@ import org.junit.Test;
public class AppTest { public class AppTest {
@Test @Test
public void test() { public void test() {
String[] args = {}; String[] args = {};
App.main(args); App.main(args);
} }
} }

View File

@ -11,33 +11,33 @@ import static org.junit.Assert.assertEquals;
public class DelegateTest { public class DelegateTest {
private static final String MESSAGE = "Test Message Printed"; private static final String MESSAGE = "Test Message Printed";
@Rule @Rule
public final SystemOutRule systemOutRule = new SystemOutRule().enableLog(); public final SystemOutRule systemOutRule = new SystemOutRule().enableLog();
@Test @Test
public void testCanonPrinter() throws Exception { public void testCanonPrinter() throws Exception {
AbstractPrinterController abstractController = new PrinterController(new CanonPrinter()); AbstractPrinterController abstractController = new PrinterController(new CanonPrinter());
abstractController.print(MESSAGE); abstractController.print(MESSAGE);
assertEquals("Canon Printer : Test Message Printed\n", systemOutRule.getLog()); assertEquals("Canon Printer : Test Message Printed\n", systemOutRule.getLog());
} }
@Test @Test
public void testHPPrinter() throws Exception { public void testHpPrinter() throws Exception {
AbstractPrinterController abstractController = new PrinterController(new HpPrinter()); AbstractPrinterController abstractController = new PrinterController(new HpPrinter());
abstractController.print(MESSAGE); abstractController.print(MESSAGE);
assertEquals("HP Printer : Test Message Printed\n", systemOutRule.getLog()); assertEquals("HP Printer : Test Message Printed\n", systemOutRule.getLog());
} }
@Test @Test
public void testEpsonPrinter() throws Exception { public void testEpsonPrinter() throws Exception {
AbstractPrinterController abstractController = new PrinterController(new EpsonPrinter()); AbstractPrinterController abstractController = new PrinterController(new EpsonPrinter());
abstractController.print(MESSAGE); abstractController.print(MESSAGE);
assertEquals("Epson Printer : Test Message Printed\n", systemOutRule.getLog()); assertEquals("Epson Printer : Test Message Printed\n", systemOutRule.getLog());
} }
} }