-
Notifications
You must be signed in to change notification settings - Fork 8
Developer Guide
amitmindstix edited this page Jan 15, 2018
·
10 revisions
- A module is a set of distinct features like cart, gallery etc.
- Features under cart module could be checkout, addtowishlist etc.
- Each feature can have scenarios. e.g. Checkout single product, Checkout multiple products
- Each module would have its own sub folder and subpackage.
- All feature files will reside under its module.
- All test classes (step definitions) reside under sub package for that module.
- All test classes will be named as
<Featurename>Test.java - Each scenario can have one or more tags. Typically tags include module, feature, test-type, test-priority
- e.g.
@cart @checkout @singleproduct @smoke @medium - Tags can also be given at feature file level (typically module and feature level tags)
Source tree of the project looks like below -

-
data- Contains classes that represent test data -
page- Contains POM classes (page object model). This can have sub packages based on modules -
utils- Contains utility classes -
runner- Contains Cucumber runner class - refer RunnerCourgette.java for more details -
stepdefinition- Contains cucumber step definition classes (aka glue). This can have sub packages based on modules

-
feature- Contains cucumber feature files (may have sub folders based on modules) -
testdata- Contains test data files -
selectors.properties- Selectors (externalized for ease of collaboration) -
log4j.properties- Logging configuration (default log output is atLogs/testlogs.log)
-
build.gradle- Gradle build script -
gradle.properties- Gradle configuration. Versions of dependencies and other variables -
docker-compose.yml- Docker Compose definition of selenium-grid -
gradlew- Shell script to run gradle (Linux/Mac) -
gradlew.bat- Script to run gradle on Windows -
pom.xml- Maven build script. Deprecated. Please use gradle instead of maven. Future version may drop maven support -
.travis.yml- Travis CI configuration file. Ignore this if you are not using Travis. -
Jenkinsfile- Jenkins Pipeline definition - supporting selenium grid, slack, email notifications -
Jenkinsfile-minimal- Jenkins Pipeline definition with least complexity - used for local development