6789101112131415
public class GivWenZenWithJUnitTest { @Test public void shouldVisitCoffeeShop() throws Exception { GivWenZen gwz = new GivWenZenForJUnit(this); gwz.when("i go to the coffee shop"); gwz.then("i am happy"); }
13141516171819202122
public void foo() {} @Test public void shouldExecuteStepsWhenCreatedViaDefaultConstructor() throws Exception { //given @SuppressWarnings({"deprecation"}) GivWenZen gwz = new GivWenZenExecutor(); //when gwz.given("gwz rocks!"); //then no exception is thrown }