@cucumber.api.java.Before public void before() throws Throwable { contextProvider = CLIContextProvider.get(); contextProvider.before(); this.localRepo = contextProvider.getOrCreateRepositoryContext("localrepo"); }
@cucumber.api.java.Before(order = 1) public void before() throws Throwable { contextProvider = CLIContextProvider.get(); contextProvider.setURIBuilder(new PGTestRepoURIBuilder()); // don't call before, let DfaultStepDefinitions do it // contextProvider.before(); }
@cucumber.api.java.Before(order = 1000) // order = 1000 to make sure it runs the latest if the // @Before annotated methods public void before(Scenario scenario) throws Throwable { contextProvider = CLIContextProvider.get(); if (contextProvider.getURIBuilder() == null) { contextProvider.setURIBuilder(TestRepoURIBuilder.createDefault()); } LOG.info("'{}': Using URIBuilder {}", scenario.getName(), contextProvider.getURIBuilder().getClass().getSimpleName()); contextProvider.before(); this.localRepo = contextProvider.getOrCreateRepositoryContext("localrepo"); RevFeatureType rft = RevFeatureTypeBuilder.build(TestFeatures.pointsType); setVariable("@PointsTypeID", rft.getId().toString()); rft = RevFeatureTypeBuilder.build(TestFeatures.linesType); setVariable("@LinesTypeID", rft.getId().toString()); }
@cucumber.api.java.Before(order = 1000) // order = 1000 to make sure it runs the latest if the // @Before annotated methods public void before(Scenario scenario) throws Throwable { contextProvider = CLIContextProvider.get(); if (contextProvider.getURIBuilder() == null) { contextProvider.setURIBuilder(TestRepoURIBuilder.createDefault()); } LOG.info("'{}': Using URIBuilder {}", scenario.getName(), contextProvider.getURIBuilder().getClass().getSimpleName()); contextProvider.before(); this.localRepo = contextProvider.getOrCreateRepositoryContext("localrepo"); RevFeatureType rft = RevFeatureTypeBuilder.build(TestFeatures.pointsType); setVariable("@PointsTypeID", rft.getId().toString()); rft = RevFeatureTypeBuilder.build(TestFeatures.linesType); setVariable("@LinesTypeID", rft.getId().toString()); }
@cucumber.api.java.Before public void before() throws Throwable { contextProvider = CLIContextProvider.get(); contextProvider.before(); this.localRepo = contextProvider.getOrCreateRepositoryContext("localrepo"); }
/** * Initialized method for cucumber tests/scenarios annotated with {@code @FileSystemReposOnly}; * runs after {@link #before()} and replaces the {@link TestRepoURIBuilder} potentially * overwritten by another steps definition class by the default one that sets up {@code file://} * URI's. */ @cucumber.api.java.Before(value = "@FileSystemReposOnly", order = 2) public void beforeFileOnlyTest() throws Throwable { // force using file based repos only CLIContextProvider provider = CLIContextProvider.get(); provider.setURIBuilder(TestRepoURIBuilder.createDefault()); }
@cucumber.api.java.Before(order = 1000) // order = 1000 to make sure it runs the latest if the // @Before annotated methods public void before(Scenario scenario) throws Throwable { contextProvider = CLIContextProvider.get(); if (contextProvider.getURIBuilder() == null) { contextProvider.setURIBuilder(TestRepoURIBuilder.createDefault()); } LOG.info("'{}': Using URIBuilder {}", scenario.getName(), contextProvider.getURIBuilder().getClass().getSimpleName()); contextProvider.before(); this.localRepo = contextProvider.getOrCreateRepositoryContext("localrepo"); RevFeatureType rft = RevFeatureType.builder().type(TestFeatures.pointsType).build(); setVariable("@PointsTypeID", rft.getId().toString()); rft = RevFeatureType.builder().type(TestFeatures.linesType).build(); setVariable("@LinesTypeID", rft.getId().toString()); }
@cucumber.api.java.Before public void before() throws Throwable { contextProvider = CLIContextProvider.get(); contextProvider.before(); this.localRepo = contextProvider.getOrCreateRepositoryContext("localrepo"); tempFolder = new TemporaryFolder(); tempFolder.create(); }
/** * Initialized method for cucumber tests/scenarios annotated with {@code @FileSystemReposOnly}; * runs after {@link #before()} and replaces the {@link TestRepoURIBuilder} potentially * overwritten by another steps definition class by the default one that sets up {@code file://} * URI's. */ @cucumber.api.java.Before(value = "@FileSystemReposOnly", order = 2) public void beforeFileOnlyTest() throws Throwable { // force using file based repos only CLIContextProvider provider = CLIContextProvider.get(); provider.setURIBuilder(TestRepoURIBuilder.createDefault()); }
@cucumber.api.java.Before public void before() throws Throwable { contextProvider = CLIContextProvider.get(); contextProvider.before(); this.localRepo = contextProvider.getOrCreateRepositoryContext("localrepo"); tempFolder = new TemporaryFolder(); tempFolder.create(); }
/** * Initialized method for cucumber tests/scenarios annotated with {@code @FileSystemReposOnly}; * runs after {@link #before()} and replaces the {@link TestRepoURIBuilder} potentially * overwritten by another steps definition class by the default one that sets up {@code file://} * URI's. */ @cucumber.api.java.Before(value = "@FileSystemReposOnly", order = 2) public void beforeFileOnlyTest() throws Throwable { // force using file based repos only CLIContextProvider provider = CLIContextProvider.get(); provider.setURIBuilder(TestRepoURIBuilder.createDefault()); }