Menu
  • HOME
  • TAGS

Jbehave - Run method after a specific scenario

bdd,jbehave,gherkin

Unfortunately there isn't a way to access the META tags in the after scenario methods. As a workaround that doesn't require you to duplicate your entire scenario file couldn't you leave all of the scenarios from your current class that don't require the teardown where they are, and move the...

java.io.FileNotFoundException for jbehave/storyDurations.props

java,google-app-engine,maven,jbehave

The file that was missing to be copied over from the archetype to the new project was stories/my.story. Even though the error is about something else, I was able to get this error to go away when I copied over the my.story file: [INFO] --- jbehave-maven-plugin:3.9.5:run-stories-as-embeddables (embeddable-stories) @ followerdownloader-frontend ---...

BDD good for UI automation?

cucumber,testng,bdd,jbehave,gherkin

BDD is about talking through examples of how a piece of code, an application, or a system should behave, then capturing those examples, often using a BDD tool and / or automation framework. Plenty of people get value just from capturing the examples on a wiki. There are four things...

IntelliJ IDEA, jbehave support plugin cannot find declaration to go to

java,maven,intellij-idea,jbehave,jbehave-plugin

Check 1st screenshot. Problem was with project(not all dependencies were resolved). After using mvn dependency:resolve the missed part of project was downloaded and now I can jump to step declaration. ...

Adding @RunWith for jbehave-junit-runner breaks JBehave build using Maven

eclipse,maven,junit,bdd,jbehave

The solution to the problem is to broaden the scope of junit by removing the test element from the junit in the pom.xml file: <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> <version>4.11</version> <!-- <scope>test</scope> --> <!-- SOLUTION: COMMENTED OUT THIS LINE --> </dependency> I think I stumbled into a paradox of JBehave and Behavior...

Io/appium/java_client/MobileElement : Unsupported major.minor version 51.0

maven,appium,jbehave

This type of error is usually related to not having JAVA_HOME set correctly. When you run from the command line with maven, it seems you have the JAVA_HOME env variable set, while when you do it using launchd you don't. Check that your /etc/launchd.conf has the line that would correctly...

JBehave dependencies not available in central maven repo?

java,maven,jbehave

You have set up a jar dependency (that is the default type) to org.jbehave:jbehave but that artifact does only have an artifact of type pom published. The dependency should look like this: <dependency> <groupId>org.jbehave</groupId> <artifactId>jbehave</artifactId> <version>4.0</version> <type>pom</type> </dependency> ...

Error producing to embedded kafka queue after upgrade from 0.7 to 0.8.1.1

java,junit,zookeeper,apache-kafka,jbehave

It turns out this has to do with the Time parameter in the new KafkaServer constructor. I was passing in a null param for the kafka.utils.Time object: private KafkaServer server = new KafkaServer(config, null); Instead, you need to create an implementation of the kafka.utils.Time interface, and pass in a new...

Custom Story Reporters in Jbehave

java,selenium,jbehave

You need to refresh some basics about java interfaces, abstract clasess and inheritation. Study these links: http://docs.oracle.com/javase/tutorial/java/concepts/interface.html http://docs.oracle.com/javase/tutorial/java/IandI/ https://docs.oracle.com/javase/tutorial/java/IandI/abstract.html org.jbehave.core.reporters.StoryReporter is an interfce that defines 21 abstract methods: http://jbehave.org/reference/stable/javadoc/core/org/jbehave/core/reporters/StoryReporter.html If you want to implement this interface in some class, you...

How to run jbehave scenario multiple times sequentially

java,jbehave

Another approach: Run jbehave scenario multiple times sequentially Narrative: In order to run jbehave scenario multiple times sequentially As a development team I want to use examples table Scenario: run jbehave scenario multiple times sequentially GivenStories: path/to/story/we/want/to/run/multiple/times/storyname.story Then some null step Examples: |x| |1| |2| ... ... ... |100000| If...

Thucydides is not starting any browser [closed]

selenium-webdriver,jbehave,thucydides

I found the resolution. This trivial thing gave me sleepless nights: In Windows ensure that the absolute path of your project should not contain any spaces. I removed spaces and its working :-)...

JBehave parametrized alias ambiguity

java,testing,jbehave

Mauro Talevi replied to me on the jBehave mailing list: http://markmail.org/thread/ef3pfkjoiuuxvic6#query:+page:1+mid:33appvwdkfboyshx+state:results The solution is to change the configuration like this: new MostUsefulConfiguration() .useParameterControls(new ParameterControls().useDelimiterNamedParameters(true)); This is probably the configuration bbark is using in its answer....

how to use Example table (Parametrised Scenarios) with normal “Given” statement

java,spring,bdd,jbehave

In cucumber using Examples is a shortcut for writing the same scenario twice with different data. So you code above is equivilent to: Scenario: test with fisrt set of data Given reference data databasetable record DEF with sds id = 2222 and swift bic = JBEHAVEXXX Given a stock of....

Thucydides Reports have no data

selenium,intellij-idea,jbehave,thucydides

Looks like there is some dependency conflict with my POM file. I have added the dependency management in the pom file and all goes well. <dependencyManagement> <dependencies> <dependency> <groupId>com.fasterxml.jackson.core</groupId> <artifactId>jackson-core</artifactId> <version>2.4.3</version> </dependency> <dependency> <groupId>com.fasterxml.jackson.core</groupId> <artifactId>jackson-databind</artifactId>...

JBehave Eclipse Plugin do not react on Ctrl+F

eclipse,search,keyboard-shortcuts,jbehave

I finally found a way to circumvent the problem, and I feel it may be of some use to other people so here it is : I opened the Preferences > Keys and copied the "Find and replace text". On the copy, I chose to set "When" to "JBehave Story...

error: method addOutcome in class OutcomesTable cannot be applied to given types

java,jbehave,hamcrest

JBehave's generic function public <T> void addOutcome(String description, T value, Matcher<T> matcher); expects that you provide the same type for T in both parameters that use T. e.g. If you pass a String value in your second parameter, then you need to provide a Matcher<String> in the third parameter. In...

Geb test withWindow not found

java,selenium,geb,jbehave

You need to use Page.getTitle() to retrieve current page title, $('title') won't work. Your code should be: @Then("target page was opened") void targetPageWasOpened() { withWindow({title == 'title'}) {at(TargetPage)} } EDIT If the window is opened asynchronously then you can wrap your code with a waitFor() call. @Then("target page was opened")...