use of cucumber.api.java.Before in project cucumber-jvm by cucumber.
the class CucumberActivitySteps method before.
@Before
public void before() {
assertEquals(0, steps);
Instrumentation instrumentation = getInstrumentation();
assertNotNull(instrumentation);
assertNotNull(getActivity());
String testPackageName = instrumentation.getContext().getPackageName();
String targetPackageName = instrumentation.getContext().getPackageName();
assertEquals(testPackageName, targetPackageName);
}
use of cucumber.api.java.Before in project cucumber-jvm by cucumber.
the class JavaHookTest method matches_matching_tags.
@Test
public void matches_matching_tags() {
objectFactory.setInstance(new HasHooks());
backend.buildWorld();
backend.addHook(BEFORE.getAnnotation(Before.class), BEFORE);
HookDefinition before = glue.getBeforeHooks().get(0);
assertTrue(before.matches(asList(new Tag("@bar", 0), new Tag("@zap", 0))));
}
use of cucumber.api.java.Before in project activityinfo by bedatadriven.
the class JsonApiSteps method setUpClient.
@Before
public void setUpClient(Scenario scenario) {
this.scenario = scenario;
this.objectMapper = new ObjectMapper();
this.jsonParser = new PsuedoJsonParser(objectMapper);
this.currentAccount = accounts.any();
}
use of cucumber.api.java.Before in project selenium_java by sergueik.
the class AngularCalculator_Steps method setup.
@Before("@Angular")
public void setup() {
driver = new ProtractorDriver();
AngularCalculatorPage.setDriver(driver);
}
use of cucumber.api.java.Before in project alien4cloud by alien4cloud.
the class EditorStepDefs method init.
@Before
public void init() throws IOException {
thrownException = null;
GetMultipleDataResult<Application> apps = alienDAO.search(Application.class, "", null, 100);
for (Application application : apps.getData()) {
applicationService.delete(application.getId());
}
FacetedSearchResult<Topology> searchResult = catalogService.search(Topology.class, "", 100, null);
Topology[] topologies = searchResult.getData();
for (Topology topology : topologies) {
try {
csarService.forceDeleteCsar(topology.getId());
} catch (NotFoundException e) {
// Some previous tests may create topology without creating any archive, if so catch the exception
alienDAO.delete(Topology.class, topology.getId());
}
}
topologyIds.clear();
editionContextManager.clearCache();
}
Aggregations