Questions tagged [cucumber-jvm]

Cucumber-JVM is a Cucumber implementation for the most popular JVM languages. Cucumber-JVM currently supports Java. There are also implementations for the following JVM languages, but as of version 2.1.0, they are unsupported: Groovy Scala Clojure Jython JRuby Rhino JavaScript Gosu

Cucumber-jvm is a Java-based tool for behavior-driven development.

Cucumber-JVM is a pure Java implementation of Cucumber, with native support for the most popular JVM languages: Java, Scala, Groovy, Clojure, Rhino, Jython and JRuby.

Cucumber-JVM is the successor of Cuke4Duke, which was the Ruby implementation of Cucumber, running on JRuby. It is faster and also easier to run than its predecessor.

See GitHub project

1356 questions
6
votes
1 answer

Set request header and User Agent in Geb

When using Geb, is it possible to set custom request headers and user agent when using the Browser API (and not the Direct Download API)? While this is possible with the FirefoxDriver (see here), I am looking for a way of doing this with the…
Behrang
  • 46,888
  • 25
  • 118
  • 160
5
votes
2 answers

Cucumber : How to read examples from external excel file for Scenarios Outline

My requirement is to read examples from external excel file rather than hard code it into feature file. I have more than 100 examples which is difficult to maintain in feature file. Can you please help me on this. Here is my scenario - Scenario…
AniSaw
  • 203
  • 4
  • 10
5
votes
0 answers

Warnings with gradle, cucumber and selenium

I am working on my automation project where I have implemented gradle with java 10 with selenium with cucumber in IntelliJ. But when I run my project I get the below warning which I unable to resolve it. Any help would really be…
Sobhit Sharma
  • 697
  • 14
  • 45
5
votes
1 answer

how to re run failed test using jvm-cucumber-parallel-plugin

I am using jvm cucumber parallel plugin and want to re-run my failed test cases. What changes are required to make in .pom file. com.github.temyers
bugCracker
  • 3,656
  • 9
  • 37
  • 58
5
votes
2 answers

How to skip all cucumber-jvm scenarios when first scenario is failed

I have 8 cucumber-jvm scenarios and the very first scenario measures the page load time and environment availability. In order to avoid unnecessary runs, if the first scenario is failed - for instance, the environment is not available, or loading…
arena
  • 233
  • 3
  • 15
5
votes
2 answers

Cucumber, Java8: find usage of step defined by lambda expression

Currently in our project's tests we switched from using annotated step definitions, e.g.: public class Steps { @Given("^Step name$") void methodName() { // do sth } } to lambda expressions: public class Steps implements En { …
DCzo
  • 141
  • 2
  • 14
5
votes
2 answers

Reports are not generated when the build is failed in Maven Cucumber Reports

Reports are generating successfully when the build is successful but when there are any failed cases which cause build failure, reports are not generated. checkBuildResult is already set to false pom file plugin
5
votes
2 answers

Running Cucumber project using Main.run from another main method

I am new to Cucumber and trying to solve simple issue: I have created a Java Project and referred all the cucumber related jars to the build-path of this project (called it "CukeTest4") and below is the structure showing the java file and feature…
user578219
  • 597
  • 2
  • 9
  • 32
5
votes
2 answers

Any cucumber Before and After hook at a feature level

i have gone through many help, but all are about explaining on scenario level. Is there any Before and After hook at feature level for cucumber JVM.? This page cucumber Hook tells about ruby language, but can i get help for java?
mmar
  • 1,840
  • 6
  • 28
  • 41
5
votes
2 answers

Is it possible to migrate from cucumber-jvm to QAF?

we already have automated testcases using cucumber-gherkin feature files with WebDriver. Right now we are able to execute feature files parallel, however we are not able to execute parallel at scenario/scenario outline level. By this way we want to…
Developer
  • 1,009
  • 8
  • 25
  • 56
5
votes
2 answers

Cucumber - How to mark expected fails as known issues?

I successfully use Cucumber to process my Java-based tests. Sometimes these tests encounter regression issues, and it takes time to fix found issues (depending on issue priority, it can be weeks or even months). So, I'm looking for a way to mark…
5
votes
0 answers

How to add RunListener and TestExecutionListeners when running with Cucumber

Our current testing framework is running with junit + spring + selenium. Our tests use both junit's org.junit.runner.notification.RunListeners and spring org.springframework.test.context.TestExecutionListeners. This is how the test definition looks…
Dana Shalev
  • 1,894
  • 1
  • 13
  • 13
5
votes
1 answer

Cucumber step with multiple DataTables

How can I write a Cucumber step that has two DataTables? How it should be written in the feature file? For example , a step to drag a row from one table to second table: When I drag a row from | column_table1 | | object1 | to …
Avi Rosenfeld
  • 305
  • 3
  • 7
  • 19
5
votes
1 answer

How do I capture STDOUT in Cucumber JVM like Cucumber Ruby's puts?

In vanilla Cucumber, anything output by a call to puts in a step definition is captured as "test output" and formatted accordingly, as in the following output example: Feature: A simple thing Scenario: A simple scenario #…
user108471
  • 2,488
  • 3
  • 28
  • 41
5
votes
3 answers

How to resolve deprecated @CucumberOptions?

In the following code i was using @cucumber.options.But it says it is deprecated. So i am trying to use @cucumberoptions which requires an import of "cucumber.api.CucumberOptions". But when i checked in my maven dependencies , cucumber.api does not…
Sapna
  • 391
  • 2
  • 3
  • 19