You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This task is to rerun the failed test cases. Since I cannot run the cucumber runner classes in order and most of the time the rerun runner class run before the actual runner, i thought of running the rerun as a separate task in gradle after the test.
So I run the gradle command like below: gradle --info clean test reRun aggregate -Denvironment='staging' -Dtags='envr:staging'
OR gradle --info clean test reRun aggregate -Denvironment='prod' -Dtags='envr:prod'
@RunWith(CucumberWithSerenity.class)
@CucumberOptions(features= "src/test/resources/features/ui/", glue = "com.a.b.c.features", plugin = {"pretty","rerun:target/failedrerun.txt"}, monochrome = true, tags = "@envr=staging and @UI")
public class CucumberSerenityBDDUIAutoRunner {
@WithTag("envr:stagging")
public void run_stagging_tests(){}
@WithTag("envr:prod")
public void run_production_tests(){}
}
The above runner runs fine as test task and parse staging/prod values from serenity.conf file but the reRun task could not do the same and the url is always empty when the test runs.
Please let me know how can I work around this issue.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I have **serenity.conf ** like below
I have a gradle task like blow
This task is to rerun the failed test cases. Since I cannot run the cucumber runner classes in order and most of the time the rerun runner class run before the actual runner, i thought of running the rerun as a separate task in gradle after the test.
So I run the gradle command like below:
gradle --info clean test reRun aggregate -Denvironment='staging' -Dtags='envr:staging'
OR
gradle --info clean test reRun aggregate -Denvironment='prod' -Dtags='envr:prod'
The above runner runs fine as test task and parse staging/prod values from serenity.conf file but the reRun task could not do the same and the url is always empty when the test runs.
Please let me know how can I work around this issue.
Beta Was this translation helpful? Give feedback.
All reactions