serenity-bdd

How do i execute story files in specific order in serenity BDD Jbehave

隐身守侯 提交于 2019-12-12 02:09:58
问题 I Have few jbehave story files in stories folder. whenever i execute the scripts it takes in alphabetical order. ex: current execution aaa.story bbb.story ccc.story i want the execution to be ccc.story bbb.story and skip aaa.story is there a way to run specific stories in specific order. in Serenity BDD + Jbehave 回答1: You can use Meta: to tag stories/scenarios. This is useful if you want to run just subset of stories/scenarios or skip some of them. Example: Meta: @sometag Scenario: some

How to assert that web element is visible on the screen using serenity-js?

眉间皱痕 提交于 2019-12-11 15:11:01
问题 I am using Serenity-js BDD framework with screenplay pattern in my project. Here I am not able to perform assertion for visibility of an element on web-page using Ensure class's "that" method. Code : Page Element - static searchPatientsVerificationRow = Target.the('verification record').located(by.xpath("//div[@class='row']//tr")); Test Script Step : return Ensure.that(TaggingSearchControls.searchPatientsVerificationRow,Is.visible()) Error : Argument of type 'SuccessCondition' is not

Why is my Spring JUnit Test Rule not running?

扶醉桌前 提交于 2019-12-11 10:23:48
问题 I've been struggling to find an obvious solution to why the linked code will not run JUnit TestRules. I've created a success case where TestRules execute, and a failure case that shows a situation where TestRules fail. Is anybody able to see why the TestRules are not being picked up? It's not just Spring's TestRule not being picked up. It seems to be all TestRules, as demonstrated by MyTestRule.java in the source code. Running mvn clean install on the success case, will see all tests passing.

How do I get the value of a key if it contains a space in Rest Assured / Serenity?

风格不统一 提交于 2019-12-11 04:45:52
问题 I am trying to use Rest Assured in the Serenity framework to validate an endpoint response. I send an xml body to the endpoint and expect a JSON response back like so: {"Entry ID" : "654123"} I want to send the XML and verify in the JSON response that the value of the key "Entry ID" is not empty or null. The problem is, the key has a space in it, and I believe it is causing an error. Here is what I have so far: SerenityRest.given().contentType(ContentType.XML) .body(xmlBody) .when().accept

Dependency convergence error

落花浮王杯 提交于 2019-12-10 22:02:21
问题 After updating Firefox I changed versions of libraries to higher ones. Following errors appeard: [ERROR] Dependency convergence error for commons-collections:commons-collections:3.2.2 paths to dependency are: [ERROR] +-net:serenity.pom.gradle:0.0.1-SNAPSHOT [ERROR] +-net.serenity-bdd:serenity-core:1.1.29-rc.3 [ERROR] +-org.seleniumhq.selenium:htmlunit-driver:2.20 [ERROR] +-commons-collections:commons-collections:3.2.2 [ERROR] and [ERROR] +-net:serenity.pom.gradle:0.0.1-SNAPSHOT [ERROR] +-net

missing pie chart and other elements when display serenity report from jenkins

岁酱吖の 提交于 2019-12-10 16:22:05
问题 Need your help! I've been working on integrating my automation test to Jenkins. I use Serenity BDD and JBehave. My Serenity report displayed OK when I run my test manually. But, when I integrate the test to Jenkins and try to display the report through Publish HTML Report Plugin, it can't display the pie chart and missing other elements as well. Any idea how to solve this? 回答1: Actually you don't need to downgrade Jenkins. This issue happens because of new content security policy headers that

Rerunning the failed scenario using Maven/Cucumber/Serenity

≡放荡痞女 提交于 2019-12-09 19:46:53
问题 Has anyone used maven surefire plug-in or any other mechanism for rerunning failed scenario. I am using Cucumber with Serenity and Maven. I tried below different ways in order to rerun failed scenario without any manual intervention For example: If out of 5 test cases 2 test cases are getting error out then automatically my script should execute these 2 failed scenario before generating final serenity report 1. Maven surefire I have added below lines in pom.xml file <properties> <failsafe

How to debug Firefox alert box closing automatically and being unable to detect the alert in Serenity BDD?

不打扰是莪最后的温柔 提交于 2019-12-08 04:11:32
问题 [main] ERROR net.serenitybdd.core.Serenity - No alert is present (WARNING: The server did not provide any stacktrace information) My question is exactly similar to this one "Firefox alert box not detected with Selenium WebDriver" But I am not able to find the solution. Even I have tried all kind of waits, changed Firefox versions and tried the solution mentioned in the shared link. But, either I am not able to implement it or its not working. When doing this task manually pop up comes up when

Running Serenity -Cucumber Test cases in parallel

大城市里の小女人 提交于 2019-12-03 20:39:12
I'm new to Serenity and BDD. I've a small demo project based on Serenity-Cucumber and Page Based model. Below is the structure of the project: The Login and Logout features have around 8 scenarios. I want to be able to run the feature files in parallel. What is the easiest and most effective way to achieve this? So far I have Created separate Runner class for each feature and then used failsafe or surefire plugin - This is something I don't want as I don't want a new runner for each feature file. Used the "cucumber-vm-parallel-plugin". I copy pasted below code in my pom file. Nothing happened.

Chrome is being controlled by automated test software

冷暖自知 提交于 2019-11-30 08:31:19
I am running automated tests in Chrome with Serenity BDD (Selenium). I had to download a new ChromeDriver, because my tests could not run -> The test would open ChromeDriver but could not "Browse as user". When I googled the issue, they said I had to update ChromeDriver. So I updated ChromeDriver to version 2.28 and I also updated the Chrome version to Version 57.0.2987.98. But now - EVERY TIME I run my tests this annoying text comes up: Chrome is being controlled by automated test software And it asks me if I want to save password. (I can't add pictures because I don't have enough "points")