Questions tagged [cucumber]

Cucumber is a tool for running automated acceptance tests written in a BDD (behaviour-driven development) style.

27 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
3
votes
1answer
484 views

Unable to launch Safari on iOS using Appium

I am automating some tests a real device (iOS) using Appium and Cucumber. My idea it to do the following steps: Open the app Do some tasks Launch Safari Navigate to a website, lets say google.com ...
2
votes
0answers
516 views

How can I make my solution thread safe for testNG parallel execution?

Background: For quite some time I have ran automated tests using forked JVM processes, this proved quite easy when injecting a driver object using spring, I could simply provide the following: @Bean(...
2
votes
0answers
848 views

How to run same test case in different browsers in Cucumber using Java

New to automation and Cucumber. I have a .feature test case (a simple login function) that I would like to run in multiple browsers in parallel. I want to store the browser properties in a global ...
2
votes
0answers
1k views

Can't run tests from Cucumber feature.file (cucumber.runtime.CucumberException:)

I can run my tests from my runner class without any problem. Here is my Runner-class: @RunWith(Cucumber.class) @CucumberOptions( format = {"pretty", "html:target/cucumber"}, glue = {"...
2
votes
0answers
967 views

Cucucmber-Jvm (Using Maven Project) + Selenium WebDriver + PageObjects + Allure Report

I am working on "Cucucmber-Jvm (Using Maven Project) + Selenium WebDriver + PageObjects + Allure Report", I am able to run my script but enable to run my script and also unable generate "Allure" ...
2
votes
1answer
5k views

Using Protractor Cucumber JS: When running a test, the test passes when it shouldn't

I'm writing a test where I should log in. It passed given the proper inputs but when I change its password/username to garbage, it still passes. I'm new to this and I really think I missed something ...
1
vote
0answers
19 views

IntelliJ feature file undefined step reference with import io.cucumber.java.en.Given

I have a feature file with the following: Scenario: Test something Given I do something to test something My step definition: import io.cucumber.java.en.Given; ... @Given("I do something to ...
1
vote
0answers
45 views

Is it possible to write good Code (create a good code framework) AND use Cucumber (or another Gherkin tool)?

When I look at the code Cucumber outputs, it does not seem to follow best practices (or any moderately good practices) for writing a testing framework. Question: Is there a way to use Cucumber and ...
1
vote
0answers
17 views

Is it possible to have different logger paths per cucumber features or scenarios?

So I'm using selenium with cucumber and right now and run my tests sequentially, at the end of the execution I collect the log and the prints. My question is, once I start executing them in parallel, ...
1
vote
0answers
58 views

Runners for cucumber tests

I've reached the point now where we need to get my automated checks running as part of deployment scripts to act as regression tests. I've not done this before and I'm thinking the way I currently ...
1
vote
1answer
229 views

CLEAR Method skipped while running the tests

I'm writing automation script for a page in which there is a text box. The scenario is as follows: I click on the text box and enter value which will throw error I clear the text box and add valid ...
1
vote
0answers
4k views

Does Robot Framework have more to offer than Cucumber?

I have some experience with Robot Framework + Selenium and am now learning Cucumber, since I noticed it's one of the most widely used frameworks in test automation. However, from what I've seen so far,...
1
vote
0answers
301 views

Couldn't able to run the testng script in Maven using cucumber

Below is the TestRunner class: import org.junit.runner.RunWith; import cucumber.api.CucumberOptions; import cucumber.api.junit.Cucumber; import cucumber.api.testng.AbstractTestNGCucumberTests; //@...
1
vote
0answers
264 views

Running a Cucumber test runner without executing the tests

One of the Cucumber options is to create a .html report or .json file of the features being run in a given test. Every time you execute a test run, it runs through the tests and at the end of a run ...
1
vote
0answers
840 views

Specifying and running multiple goals in Maven

I have created a testing framework using Cucumber, Selenium and Maven. I am using the cucumber-jvm-parallel plugin to run my tests in parallel. Below is how my pom.xml looks: <?xml version="1.0" ...
0
votes
1answer
43 views

Using a small number of available user properties across a large number of threads

I'm currently building a testing framework for functional tests. I can run them in parallel using Cucumber but I have run into a problem in creating users for each thread (each test requires a brand ...
0
votes
0answers
81 views

getting null pointer exception for different step definition files with cucumber and selenium

Browser utility: package com.gmsr.utility; import java.util.concurrent.TimeUnit; import org.openqa.selenium.WebDriver; import org.openqa.selenium.chrome.ChromeDriver; public class BrowserUtility { ...
0
votes
0answers
258 views

Cucumber and TestNG, how to pass parameter?

Could you please tell, how to pass parameter in Cucumber using TestNG? I have following code, but it does not work. Error in stepDefinition.java on the line @Parameters({"environment"}) testng.xml &...
0
votes
1answer
47 views

How to Embed / Attach screenshots when each step is executed in Cucumber

I need to take screenshots after each Steps execution and embed them in the results.i have tried in using the "After" method but its capture only the last screen and displaying in the end of the ...
0
votes
1answer
61 views

Why Cucumber repeats Java/Selenium exception text?

For example, tried to locale a web page element by ID and it was not there - why Cucumber repeats the Java output (in addition to - expected - its own scenario/feature/steps failure text) and can I ...
0
votes
1answer
49 views

How to keep a single browser window open during multiple search for a website in the code?

I want to search for different items in a website multiple times and add the item to cart after each search and proceed to checkout after last search. Cucumber opens the new browser for every row in ...
0
votes
0answers
228 views

Cucumber JS Step Definitions Coming Incorrect For Scenario Outline

Currently working with the .js port of Cucumber - CucumberJS. I am facing this issue where the scenario outline steps are not coming in the defined step. My Scenario is pretty simple Scenario ...
0
votes
2answers
359 views

Unable to read the parameter value inside a class using TestNG

To achieve parallel execution, I am updating my existing Junit project to TestNG. The requirement here is to run one scenario in different browsers using TestNG RunnerClass is as follows: import ...
0
votes
4answers
58 views

How can we manage cucumber background information when require hard set data aliases?

Consider a bunch of scenarios grouped into one feature file that all require setting up a valid user, however I do not want to generate such a user dynamically, for example: Background: Creating a ...
-1
votes
0answers
43 views

Testing Frameworks Confusion: Cucumber.io and Robot Frameworks

I am researching a few testing frameworks for testing non-web projects, mostly Java and C++ projects (and perhaps some Python projects). I have gotten somewhat confused about Cucumber.io and Robot ...
-1
votes
1answer
235 views

How to get iteration count in cucumber?

I wanted to get iteration count in cucumber when we are executing feature file with multiple row from example in feature file.
-1
votes
1answer
56 views

Multiple browser support

Currently our automation suite runs on chrome (has been designed for chrome). We used cucumber with Java and Selenium. We are trying to make the current automation suite multi-browser compatible. The ...