Class SmartCucumberApiScenarioContext
java.lang.Object
org.uitnet.testing.smartfwk.api.core.defaults.SmartCucumberApiScenarioContext
- All Implemented Interfaces:
SmartCucumberScenarioContext
public class SmartCucumberApiScenarioContext extends Object implements SmartCucumberScenarioContext
This class is used as cucumber scenario context to keep the information for
the running scenario. using this class we can pass the information from one
scenario to another scenario.
This class must be injected in the cucumber step definition constructor.
After that any step definition as part of one scenario can access the
information from this class.
NOTE: We must have cucumber-picocontainer jar dependency in our Maven or
gradle build configuration (as part of cucumber documentation).
- Author:
- Madhav Krishna
-
Constructor Summary
Constructors Constructor Description SmartCucumberApiScenarioContext() -
Method Summary
-
Constructor Details
-
SmartCucumberApiScenarioContext
public SmartCucumberApiScenarioContext()
-
-
Method Details
-
getScenario
public io.cucumber.java.Scenario getScenario()- Specified by:
getScenarioin interfaceSmartCucumberScenarioContext
-
setScenario
public void setScenario(io.cucumber.java.Scenario scenario)- Specified by:
setScenarioin interfaceSmartCucumberScenarioContext
-
getActionHandler
-
switchTargetServer
public AbstractApiActionHandler switchTargetServer(String appName, String targetServerName, String userProfileName) -
login
public AbstractApiActionHandler login(String appName, String targetServerName, String userProfileName) -
getActiveAppName
- Specified by:
getActiveAppNamein interfaceSmartCucumberScenarioContext
-
setActiveUserProfile
public AbstractApiActionHandler setActiveUserProfile(String appName, String targetServerName, String userProfileName) -
setActiveUserProfileOnActiveAppAndTargetServer
public AbstractApiActionHandler setActiveUserProfileOnActiveAppAndTargetServer(String userProfileName) -
getActiveActionHandler
-
getActiveUserProfileNameOfActiveActionHandler
-
getTestConfigManager
- Specified by:
getTestConfigManagerin interfaceSmartCucumberScenarioContext
-
getActiveAppConfig
- Specified by:
getActiveAppConfigin interfaceSmartCucumberScenarioContext
-
getActiveAppApiConfig
-
getAppConfig
- Specified by:
getAppConfigin interfaceSmartCucumberScenarioContext
-
log
- Specified by:
login interfaceSmartCucumberScenarioContext
-
close
public void close()- Specified by:
closein interfaceSmartCucumberScenarioContext
-
addParamValue
- Specified by:
addParamValuein interfaceSmartCucumberScenarioContext
-
getParamValue
- Specified by:
getParamValuein interfaceSmartCucumberScenarioContext
-
removeParam
- Specified by:
removeParamin interfaceSmartCucumberScenarioContext
-