I use Karate software and I want include some scenarios into one features - run it in non parallel state, scenarios needed to be run in order from to the top to the down.
I have following code:
@parallel=false
Feature: TC_C - Component detail check
Scenario: Check component detail
# Login (prerequisity)
* call read('classpath:ui/common/login.feature')
* waitForUrl('/applications')
* match driver.url == baseUrl + 'applications'
# Step 0 (Create an application and a component inside)
* call read('classpath:ui/common/applicationCreation.feature')
* call read('classpath:ui/common/componentCreation.feature')
Scenario: Step1
# Step 1
When retry(20, 3000).click('//*[normalize-space(text()) = \'' + compName + '\']/../td/a/span[2][normalize-space(text()) = \'Detail\']/..')
Then waitForText('.card-header', 'Component Detail')
"Scenario: Check component detail" passes successfully.
Problem is with first row of second scenario where an error occurs:
com.intuit.karate.exception.KarateException: TC_C.feature:18 - javascript evaluation failed: retry(20, 3000).click('//*[normalize-space(text()) = \'' + compName + '\']/../td/a/span[2][normalize-space(text()) = \'Detail\']/..'), ReferenceError: "retry" is not defined in <eval> at line number 1
It seems to be trouble with retry and I have no idea how to run it without the error...
I have tried it in different places but trouble with retry occurs evenif without separation to more Scenarios it works properly.. If there is no split into two scenarios and only one scenario exists everything works ok.
Why I am doing it is that I want to have feature including Multiple scenatios (outline scenario(s) or standard scenario(s))
If you have any idea I will be pleased. Thank you.