30313233343536373839
} public static void main(String... args) { /** Make a test client, then execute its tests **/ WelcomeJDKTest tester = new WelcomeJDKTest(new WelcomeBean()); tester.testWelcome(); tester.testWelcomeRequiresInput(); }
29303132333435
private WelcomeBean welcomer; /** Called by TestNG before each {@link Test} method **/ @BeforeTest public void makeWelcomer() { this.welcomer = new WelcomeBean(); }
private WelcomeBean welcomer; /** Called by JUnit before each {@link Test} method **/ @Before public void makeWelcomer() { this.welcomer = new WelcomeBean(); }