cucumber-jvm

Running Cucumber tests directly from executable jar

喜你入骨 提交于 2019-11-27 01:59:58
问题 I have a project with cucumber and maven also I am using the JUnit. I am able to run and build my project successfully from Eclipse. Now I want to run the test from command line in another system which does(should) not have eclipse or cucumber installed. I have an idea that we can create a JAR from jar we can run the tests by java cli commands. Below are the combinations I am trying to run my tests from , also I am pasting the pom.xml and RunCukesTest.java file.. pom.xml <project xmlns="http:

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

对着背影说爱祢 提交于 2019-11-26 21:58:01
问题 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 <plugin> <groupId>net.masterthought</groupId> <artifactId>maven-cucumber-reporting</artifactId> <version>3.13.0</version> <executions> <execution> <id>execution</id> <phase>verify</phase> <goals> <goal>generate</goal> </goals> <configuration> <projectName>Simplify360 Automation Test

How to run cucumber file from command line

梦想与她 提交于 2019-11-26 21:50:50
问题 I have cucumber feature file located at below location on my local: C:\ProjectWork\Workspace\Cucumber\DIT_Cucumber\src\cucumber\featureOne.feature and Junit jar at below location: C:\DurgeshProjectWork\Workspace\JarFiles\junit-4.11.jar When I have tried several commands like below to execute the feature file from command prompt however all the time getting same error as Could not fine class Below are the commands which I used: Command 1: C:\>java -cp C:\ProjectWork\Workspace\JarFiles\junit-4

In Karate how we can collaboratively work along with BA to automate business scenarios

a 夏天 提交于 2019-11-26 19:09:24
While using Karate we were able to do most of the validations for web services, we were able to successfully integrate Karate with Selenium webdriver and do DB assertions using java classes. For DB we returned the results sets as list by converting each row as a hashmap and Karate took it as json array. So the validations became simple. Most of the needs for us on a QA side have been achieved using Karate. However, today when we introduced, it to a bigger community one of the dev lead came up with a question. He is an expert in JBehave, BDD, jsonpath, java, web services etc. We also felt his

Sharing same selenium WebDriver between step definition files

左心房为你撑大大i 提交于 2019-11-26 16:32:55
问题 Right now we're working on adopting Cucumber to run functional tests on our Java8/Spring app. We want our step definition files to remain as DRY as possible and as such plan on using the same step definitions in different feature files. Since we are using a selenium WebDriver to drive our tests, we need to share the same driver between step definitions. To demonstrate why having multiple drivers is an issue for us, imagine a feature file that defines two steps: one to navigate to a page, and

Good practice to pass variables between cucumber-jvm steps

一曲冷凌霜 提交于 2019-11-26 12:58:15
问题 To pass variables between steps now I\'m doing something like the example as follows: Feature: Demo Scenario: Create user Given User creation form management When Create user with name \"TEST\" Then User is created successfully Java class with steps definitions: public class CreateUserSteps { private String userName; @Given(\"^User creation form management$\") public void User_creation_form_management() throws Throwable { // ... } @When(\"^Create user with name \\\"([^\\\"]*)\\\"$\") public

In Karate how we can collaboratively work along with BA to automate business scenarios

对着背影说爱祢 提交于 2019-11-26 04:55:18
问题 While using Karate we were able to do most of the validations for web services, we were able to successfully integrate Karate with Selenium webdriver and do DB assertions using java classes. For DB we returned the results sets as list by converting each row as a hashmap and Karate took it as json array. So the validations became simple. Most of the needs for us on a QA side have been achieved using Karate. However, today when we introduced, it to a bigger community one of the dev lead came up

How to execute cucumber feature file parallel

佐手、 提交于 2019-11-26 00:48:56
问题 I have below feature files (Separate feature files) in src/test/resources/feature/ and I would like to run them in parallel. Like: One feature file has to execute in chrome and another one has to execute in firefox as mentioned @Tags name. Feature: Refund item @chrome Scenario: Jeff returns a faulty microwave Given Jeff has bought a microwave for $100 And he has a receipt When he returns the microwave Then Jeff should be refunded $100 Feature: Refund Money @firefox Scenario: Jeff returns the