This is a demo project showcasing Automation test using BDD framework.
- Open command prompt and take a pull of this repository.
git clone https://github.com/arghajit/basic-facebook-login.git
- Go inside the root directory.
cd basic-facebook-login/basicfacebooklogin
- Run the tests.
mvn clean test
- Please go to
mytest.feature
file and change the facebook username and password with a valid ones. - Please download chromedriver and add it to your
PATH
environment variable.
- This framework is build with Page Object Model format where each classes in
pages
dir defines an actual webpage. - Tests are built with BDD flavour.
- At the time of execution JUnit runner bind the
Cucumber.class
and its subordinate feature files withstepdefinations.java
. stepdefination.java
file initiates thedriver
instance and communicate with POM classes.
- Java
- Cucumber JVM (BDD framework)
- JUnit 4
- Maven
- Selenium
.
└── basic-facebook-login
├── README.md
└── basicfacebooklogin
├── Report # Generated Reports comes here
│ └── ExtentReport.html
├── pom.xml
└── src
├── main
│ └── java
│ ├── pages # Page object models of Facebook
│ │ ├── homepage.java
│ │ └── newsfeed.java
│ ├── stepdefinitions # Step definations written for feature files
│ │ └── steps.java
│ └── utils
│ └── BROWSER.java # selenium driver init
└── test
└── java
├── features # feature files
│ └── mytest.feature
└── tests
└── TestRunner.java # JUnit Test file