class CucumberBuiltinKeywords extends com.kms.katalon.core.keyword.BuiltinKeywords
| Fields inherited from class | Fields |
|---|---|
class com.kms.katalon.core.keyword.BuiltinKeywords |
__$stMC |
| Constructor and description |
|---|
CucumberBuiltinKeywords
() |
| Type Params | Return Type | Name and description |
|---|---|---|
|
static CucumberRunnerResult |
runFeatureFile(String relativeFilePath, com.kms.katalon.core.model.FailureHandling flowControl)Runs the given Feature file with featureId by invoking
cucumber.api.cli.Main#run(String[], ClassLoader).
|
|
static CucumberRunnerResult |
runFeatureFile(String relativeFilePath)Runs the given Feature file with featureId by invoking
cucumber.api.cli.Main#run(String[], ClassLoader).
|
|
static CucumberRunnerResult |
runFeatureFileWithTags(String relativeFilePath, String[] tags, com.kms.katalon.core.model.FailureHandling flowControl)Runs the given Feature file with featureId by invoking
cucumber.api.cli.Main#run(String[], ClassLoader).
|
|
static CucumberRunnerResult |
runFeatureFileWithTags(String relativeFilePath, String[] tags)Runs the given Feature file with featureId by invoking
cucumber.api.cli.Main#run(String[], ClassLoader).
|
|
static CucumberRunnerResult |
runFeatureFolder(String folderRelativePath, com.kms.katalon.core.model.FailureHandling flowControl)Runs the given Feature folder and its nested sub-folder with folderRelativePath
by invoking cucumber.api.cli.Main#run(String[], ClassLoader).
|
|
static CucumberRunnerResult |
runFeatureFolder(String folderRelativePath)Runs the given Feature folder and its nested sub-folder with folderRelativePath
by invoking cucumber.api.cli.Main#run(String[], ClassLoader).
|
|
static CucumberRunnerResult |
runFeatureFolderWithTags(String folderRelativePath, String[] tags, com.kms.katalon.core.model.FailureHandling flowControl)Runs the given Feature folder and its nested sub-folder with folderRelativePath
by invoking cucumber.api.cli.Main#run(String[], ClassLoader).
|
|
static CucumberRunnerResult |
runFeatureFolderWithTags(String folderRelativePath, String[] tags)Runs the given Feature folder and its nested sub-folder with folderRelativePath
by invoking cucumber.api.cli.Main#run(String[], ClassLoader)
The generated reports will be extracted in the current report folder with the following path: <report_folder>/cucumber_report/<current_time_stamp> |
|
static CucumberRunnerResult |
runWithCucumberRunner(Class cucumberRunnerClass, com.kms.katalon.core.model.FailureHandling flowControl)Runs the given cucumberRunnerClass that is annotated with Cucumber runner by invoke JUnit
runner. |
|
static CucumberRunnerResult |
runWithCucumberRunner(Class cucumberRunnerClass)Runs the given cucumberRunnerClass that is annotated with Cucumber runner by invoke JUnit
runner. |
| Methods inherited from class | Name |
|---|---|
class com.kms.katalon.core.keyword.BuiltinKeywords |
com.kms.katalon.core.keyword.BuiltinKeywords#delay(java.lang.Number), com.kms.katalon.core.keyword.BuiltinKeywords#delay(java.lang.Number, com.kms.katalon.core.model.FailureHandling), com.kms.katalon.core.keyword.BuiltinKeywords#comment(java.lang.String), com.kms.katalon.core.keyword.BuiltinKeywords#verifyMatch(java.lang.String, java.lang.String, boolean, com.kms.katalon.core.model.FailureHandling), com.kms.katalon.core.keyword.BuiltinKeywords#verifyMatch(java.lang.String, java.lang.String, boolean), com.kms.katalon.core.keyword.BuiltinKeywords#verifyNotMatch(java.lang.String, java.lang.String, boolean, com.kms.katalon.core.model.FailureHandling), com.kms.katalon.core.keyword.BuiltinKeywords#verifyNotMatch(java.lang.String, java.lang.String, boolean), com.kms.katalon.core.keyword.BuiltinKeywords#verifyEqual(java.lang.Object, java.lang.Object), com.kms.katalon.core.keyword.BuiltinKeywords#verifyEqual(java.lang.Object, java.lang.Object, com.kms.katalon.core.model.FailureHandling), com.kms.katalon.core.keyword.BuiltinKeywords#verifyNotEqual(java.lang.Object, java.lang.Object, com.kms.katalon.core.model.FailureHandling), com.kms.katalon.core.keyword.BuiltinKeywords#verifyNotEqual(java.lang.Object, java.lang.Object), com.kms.katalon.core.keyword.BuiltinKeywords#verifyGreaterThan(java.lang.Object, java.lang.Object, com.kms.katalon.core.model.FailureHandling), com.kms.katalon.core.keyword.BuiltinKeywords#verifyGreaterThan(java.lang.Object, java.lang.Object), com.kms.katalon.core.keyword.BuiltinKeywords#verifyGreaterThanOrEqual(java.lang.Object, java.lang.Object, com.kms.katalon.core.model.FailureHandling), com.kms.katalon.core.keyword.BuiltinKeywords#verifyGreaterThanOrEqual(java.lang.Object, java.lang.Object), com.kms.katalon.core.keyword.BuiltinKeywords#verifyLessThan(java.lang.Object, java.lang.Object, com.kms.katalon.core.model.FailureHandling), com.kms.katalon.core.keyword.BuiltinKeywords#verifyLessThan(java.lang.Object, java.lang.Object), com.kms.katalon.core.keyword.BuiltinKeywords#verifyLessThanOrEqual(java.lang.Object, java.lang.Object, com.kms.katalon.core.model.FailureHandling), com.kms.katalon.core.keyword.BuiltinKeywords#verifyLessThanOrEqual(java.lang.Object, java.lang.Object), com.kms.katalon.core.keyword.BuiltinKeywords#verifyCheckpoint(com.kms.katalon.core.checkpoint.Checkpoint, boolean), com.kms.katalon.core.keyword.BuiltinKeywords#verifyCheckpoint(com.kms.katalon.core.checkpoint.Checkpoint, boolean, com.kms.katalon.core.model.FailureHandling), com.kms.katalon.core.keyword.BuiltinKeywords#getMetaClass(), com.kms.katalon.core.keyword.BuiltinKeywords#setMetaClass(groovy.lang.MetaClass), com.kms.katalon.core.keyword.BuiltinKeywords#callTestCase(com.kms.katalon.core.testcase.TestCase, java.util.Map), com.kms.katalon.core.keyword.BuiltinKeywords#callTestCase(com.kms.katalon.core.testcase.TestCase, java.util.Map, com.kms.katalon.core.model.FailureHandling), com.kms.katalon.core.keyword.BuiltinKeywords#concatenate([Ljava.lang.String;), com.kms.katalon.core.keyword.BuiltinKeywords#concatenate([Ljava.lang.String;, com.kms.katalon.core.model.FailureHandling), com.kms.katalon.core.keyword.BuiltinKeywords#wait(long, int), com.kms.katalon.core.keyword.BuiltinKeywords#wait(), com.kms.katalon.core.keyword.BuiltinKeywords#wait(long), com.kms.katalon.core.keyword.BuiltinKeywords#equals(java.lang.Object), com.kms.katalon.core.keyword.BuiltinKeywords#toString(), com.kms.katalon.core.keyword.BuiltinKeywords#hashCode(), com.kms.katalon.core.keyword.BuiltinKeywords#getClass(), com.kms.katalon.core.keyword.BuiltinKeywords#notify(), com.kms.katalon.core.keyword.BuiltinKeywords#notifyAll(), com.kms.katalon.core.keyword.BuiltinKeywords#getProperty(java.lang.String), com.kms.katalon.core.keyword.BuiltinKeywords#setProperty(java.lang.String, java.lang.Object), com.kms.katalon.core.keyword.BuiltinKeywords#invokeMethod(java.lang.String, java.lang.Object) |
Runs the given Feature file with featureId by invoking
cucumber.api.cli.Main#run(String[], ClassLoader).
If your step definitions are in packages, you can set glue path to help system can detect your step definitions path easier.
<report_folder>/cucumber_report/<current_time_stamp>
Examples:
- Example #1: Run a single feature file
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
import com.kms.katalon.core.model.FailureHandling
CucumberKW.runFeatureFile('Include/features/New Feature File.feature', FailureHandling.STOP_ON_FAILURE)
- Example #2: Run a single feature file and the step definitions is in pre-defined packages
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
import com.kms.katalon.core.model.FailureHandling
CucumberKW.GLUE = ['mypackage1', 'mypackage2']
CucumberKW.runFeatureFile('Include/features/New Feature File.feature', FailureHandling.STOP_ON_FAILURE)
- Parameters:
relativeFilePath
- relativeFilePath of Feature fileflowControl
- an instance com.kms.katalon.core.model.FailureHandling that controls the running flow
- Returns:
- an instance of CucumberRunnerResult that includes status of keyword and report folder location.
- Since:
- 5.7
- See Also:
- CucumberRunnerResult
Runs the given Feature file with featureId by invoking
cucumber.api.cli.Main#run(String[], ClassLoader).
If your step definitions are in packages, you can set glue path to help system can detect your step definitions
path easier.
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
CucumberKW.runFeatureFile('Include/features/New Feature File.feature')
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
CucumberKW.GLUE = ['mypackage1', 'mypackage2']
CucumberKW.runFeatureFile('Include/features/New Feature File.feature')
relativeFilePath
- relativeFilePath of Feature file Runs the given Feature file with featureId by invoking
cucumber.api.cli.Main#run(String[], ClassLoader).
If your step definitions are in packages, you can set glue path to help system can detect your step definitions path easier.
<report_folder>/cucumber_report/<current_time_stamp>
Examples:
- Example #1: Run a single feature file with selected tags
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
import com.kms.katalon.core.model.FailureHandling
CucumberKW.runFeatureFile('Include/features/New Feature File.feature', ['@foo', 'not @bar'] as [], FailureHandling.STOP_ON_FAILURE)
- Example #2: Run a single feature file with selected tags and the step definitions is in pre-defined packages
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
import com.kms.katalon.core.model.FailureHandling
CucumberKW.GLUE = ['mypackage1', 'mypackage2']
CucumberKW.runFeatureFile('Include/features/New Feature File.feature', ['@foo', 'not @bar'] as [], FailureHandling.STOP_ON_FAILURE)
@bar']: Select all foo tags but not bar tags - Parameters:
relativeFilePath
- relativeFilePath of the feature filetags
- what tags in the features should be executed. Eg: ['@foo', 'notflowControl
- an instance com.kms.katalon.core.model.FailureHandling that controls the running flow
- Returns:
- an instance of CucumberRunnerResult that includes status of keyword and report folder location.
- Since:
- 7.0.0
- See Also:
- CucumberRunnerResult
Runs the given Feature file with featureId by invoking
cucumber.api.cli.Main#run(String[], ClassLoader).
If your step definitions are in packages, you can set glue path to help system can detect your step definitions
path easier.
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
import com.kms.katalon.core.model.FailureHandling
CucumberKW.runFeatureFile('Include/features/New Feature File.feature', ["@foo", "not @bar"] as [], FailureHandling.STOP_ON_FAILURE)
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
import com.kms.katalon.core.model.FailureHandling
CucumberKW.GLUE = ['mypackage1', 'mypackage2']
CucumberKW.runFeatureFile('Include/features/New Feature File.feature', ["@foo", "not @bar"] as [], FailureHandling.STOP_ON_FAILURE)
relativeFilePath
- relativeFilePath of Feature filetags
- what tags in the features should be executed. Eg: ['@foo', 'not Runs the given Feature folder and its nested sub-folder with folderRelativePath
by invoking cucumber.api.cli.Main#run(String[], ClassLoader).
If your step definitions are in packages, you can set glue path to help system can detect your step definitions path easier.
<report_folder>/cucumber_report/<current_time_stamp>
Examples:
- Example #1: Run all features file in the specified folder
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
import com.kms.katalon.core.model.FailureHandling
CucumberKW.runFeatureFolder('Include/features', FailureHandling.STOP_ON_FAILURE)
- Example #2: Run all features file in the specified folder and the step definitions is in pre-defined packages
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
import com.kms.katalon.core.model.FailureHandling
CucumberKW.GLUE = ['mypackage1', 'mypackage2']
CucumberKW.runFeatureFolder('Include/features', FailureHandling.STOP_ON_FAILURE)
- Parameters:
folderRelativePath
- folder relative path that starts from the current project locationflowControl
- an instance com.kms.katalon.core.model.FailureHandling that controls the running flow
- Returns:
- an instance of CucumberRunnerResult that includes status of keyword and report folder location.
- Since:
- 5.7
Runs the given Feature folder and its nested sub-folder with folderRelativePath
by invoking cucumber.api.cli.Main#run(String[], ClassLoader).
If your step definitions are in packages, you can set glue path to help system can detect your step definitions path easier.
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
CucumberKW.runFeatureFolder('Include/features')
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
CucumberKW.GLUE = ['mypackage1', 'mypackage2']
CucumberKW.runFeatureFolder('Include/features')
folderRelativePath
- folder relative path that starts from current project location Runs the given Feature folder and its nested sub-folder with folderRelativePath
by invoking cucumber.api.cli.Main#run(String[], ClassLoader).
<report_folder>/cucumber_report/<current_time_stamp>
- Example #1: Run a single feature file with selected tags
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
import com.kms.katalon.core.model.FailureHandling
CucumberKW.runFeatureFolderWithTags('Include/features/New Feature File.feature', ["@foo", "not @bar"] as [], FailureHandling.STOP_ON_FAILURE)
- Example #2: Run a single feature file with selected tags and the step definitions is in pre-defined packages
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
import com.kms.katalon.core.model.FailureHandling
CucumberKW.GLUE = ['mypackage1', 'mypackage2']
CucumberKW.runFeatureFolderWithTags('Include/features/New Feature File.feature', ["@foo", "not @bar"] as [], FailureHandling.STOP_ON_FAILURE)
@bar']: Select all foo tags but not bar tags - Parameters:
folderRelativePath
- folder relative path that starts from the current project locationtags
- what tags in the features should be executed. Eg: ['@foo', 'notflowControl
- an instance com.kms.katalon.core.model.FailureHandling that controls the running flow
- Returns:
- an instance of CucumberRunnerResult that includes status of keyword and report folder location.
- Since:
- 7.0.0
Runs the given Feature folder and its nested sub-folder with folderRelativePath
by invoking cucumber.api.cli.Main#run(String[], ClassLoader)
<report_folder>/cucumber_report/<current_time_stamp>
- Example #1: Run a single feature file with selected tags
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
import com.kms.katalon.core.model.FailureHandling
CucumberKW.runFeatureFolderWithTags('Include/features/New Feature File.feature', ["@foo", "not @bar"] as [])
- Example #2: Run a single feature file with selected tags and the step definitions is in pre-defined packages
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
import com.kms.katalon.core.model.FailureHandling
CucumberKW.GLUE = ['mypackage1', 'mypackage2']
CucumberKW.runFeatureFolderWithTags('Include/features/New Feature File.feature', ["@foo", "not @bar"] as [])
@bar']: Select all foo tags but not bar tags - Parameters:
folderRelativePath
- folder relative path that starts from current project locationtags
- what tags in the features should be executed. Eg: ['@foo', 'not
- Returns:
- an instance of CucumberRunnerResult that includes status of keyword and report folder location.
- Since:
- 7.0.0
Runs the given cucumberRunnerClass that is annotated with Cucumber runner by invoke JUnit
runner.
cucumberRunnerClass
- a class that is annotated with Cucumber runner.
Example of cucumberRunnerClass:
import org.junit.runner.RunWith;
import cucumber.api.CucumberOptions;
import cucumber.api.junit.Cucumber;
@RunWith(Cucumber.class)
@CucumberOptions(features = "Include/features", glue = "")
public class MyCucumberRunner {}
import org.junit.runner.RunWith;
import cucumber.api.CucumberOptions;
import cucumber.api.junit.Cucumber;
@RunWith(Cucumber.class)
@CucumberOptions(features = "Your_Folder_Or_File_Path", glue = "")
public class MyCucumberRunner {}
import org.junit.runner.RunWith;
import cucumber.api.CucumberOptions;
import cucumber.api.junit.Cucumber;
@RunWith(Cucumber.class)
@CucumberOptions(features="Your_Folder_Path", glue="", plugin = ["pretty",
"junit:Folder_Name/cucumber.xml"])
public class MyCucumberRunner {
}
import org.junit.runner.RunWith;
import cucumber.api.CucumberOptions;
import cucumber.api.junit.Cucumber;
@RunWith(Cucumber.class)
@CucumberOptions(features="Your_Folder_Path", glue="", plugin = ["pretty",
"junit:Folder_Name/cucumber.xml",
"html:Folder_Name",
"json:Folder_Name/cucumber.json"])
public class MyCucumberRunner {
}
flowControl
- an instance com.kms.katalon.core.model.FailureHandling that controls the running flow Runs the given cucumberRunnerClass that is annotated with Cucumber runner by invoke JUnit
runner.
cucumberRunnerClass
- a class that is annotated with Cucumber runner.
Example of cucumberRunnerClass:
import org.junit.runner.RunWith;
import cucumber.api.CucumberOptions;
import cucumber.api.junit.Cucumber;
@RunWith(Cucumber.class)
@CucumberOptions(features = "Include/features", glue = "")
public class MyCucumberRunner {}
import org.junit.runner.RunWith;
import cucumber.api.CucumberOptions;
import cucumber.api.junit.Cucumber;
@RunWith(Cucumber.class)
@CucumberOptions(features = "Your_Folder_Or_File_Path", glue = "")
public class MyCucumberRunner {}
import org.junit.runner.RunWith;
import cucumber.api.CucumberOptions;
import cucumber.api.junit.Cucumber;
@RunWith(Cucumber.class)
@CucumberOptions(features="Your_Folder_Path", glue="", plugin = ["pretty",
"junit:Folder_Name/cucumber.xml"])
public class MyCucumberRunner {
}
import org.junit.runner.RunWith;
import cucumber.api.CucumberOptions;
import cucumber.api.junit.Cucumber;
@RunWith(Cucumber.class)
@CucumberOptions(features="Your_Folder_Path", glue="", plugin = ["pretty",
"junit:Folder_Name/cucumber.xml",
"html:Folder_Name",
"json:Folder_Name/cucumber.json"])
public class MyCucumberRunner {
}