diff --git a/app/build.gradle b/app/build.gradle index ead237d..219db1f 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -49,5 +49,5 @@ dependencies { compile 'com.android.support:appcompat-v7:25.2.0' - androidTestCompile 'com.mauriciotogneri:greencoffee:2.0.1' + androidTestCompile 'com.mauriciotogneri:greencoffee:2.1.1' } \ No newline at end of file diff --git a/app/src/androidTest/java/com/mauriciotogneri/greencoffeeexample/test/features/LoginFeatureTest.java b/app/src/androidTest/java/com/mauriciotogneri/greencoffeeexample/test/features/LoginFeatureTest.java index 3e5fd03..a7955be 100644 --- a/app/src/androidTest/java/com/mauriciotogneri/greencoffeeexample/test/features/LoginFeatureTest.java +++ b/app/src/androidTest/java/com/mauriciotogneri/greencoffeeexample/test/features/LoginFeatureTest.java @@ -4,6 +4,7 @@ import com.mauriciotogneri.greencoffee.GreenCoffeeConfig; import com.mauriciotogneri.greencoffee.GreenCoffeeTest; +import com.mauriciotogneri.greencoffee.Scenario; import com.mauriciotogneri.greencoffee.ScenarioConfig; import com.mauriciotogneri.greencoffeeexample.activities.LoginActivity; import com.mauriciotogneri.greencoffeeexample.test.steps.ContactListSteps; @@ -17,14 +18,12 @@ import org.junit.runners.Parameterized.Parameters; import java.io.IOException; +import java.util.Locale; import static com.mauriciotogneri.greencoffeeexample.test.TestSuite.ENGLISH; import static com.mauriciotogneri.greencoffeeexample.test.TestSuite.SPANISH; -// auto-generate the steps from gherkin -// close keyboard shortcut -// simplify signature: protected void start(GreenCoffeeSteps firstTarget, GreenCoffeeSteps... restTargets) -// flag to delete app data +// TODO: auto-generate the steps from gherkin @RunWith(Parameterized.class) public class LoginFeatureTest extends GreenCoffeeTest { @@ -49,4 +48,10 @@ public void test() { start(new LoginSteps(), new ContactListSteps(), new ScreenshotSteps()); } + + @Override + protected void beforeScenarioStarts(Scenario scenario, Locale locale) + { + // do something + } } \ No newline at end of file