Skip to content

Java Automation Framework template to create new projects

Notifications You must be signed in to change notification settings

ArCiGo/Java-Automation-Framework

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Automation framework made with Java + Selenium

The goal of this project was to put into practice my knowledge of Selenium using Java.

Do you want to create a framework based on this project? Check this branch!

The project 💻

The Automation Practice store was automated using Java + Selenium.

Tools ⚙️

  • Java v18.0.2.
  • Selenium v3.141.59.
  • TestNG v6.8.
  • log4j v2.14.1.
  • JavaFaker v1.0.2.
  • ExtentReports v5.0.9.
  • OpenCSV v4.6.
  • WebDriverManager v5.0.3.
  • Lombok v1.18.24.

Project folder structure 🗂️

.
├── .idea
├── src/
│   ├── main/
│   │   └── java/
│   │       └── PageObjectModel/
│   │           ├── Components/
│   │           │   ├── Authentication
│   │           │   ├── CreateAccount
│   │           │   ├── Home
│   │           │   ├── MyAccount
│   │           │   ├── ShoppingCartAddress
│   │           │   ├── ShoppingCartOrderInformation
│   │           │   ├── ShoppingCartOrderSummaryBankwire
│   │           │   ├── ShoppingCartPaymentMethod
│   │           │   ├── ShoppingCartShipping
│   │           │   └── ShoppingCartSummary
│   │           ├── Models
│   │           ├── Pages
│   │           └── Utilities
│   └── test/
│       ├── java/
│       │   ├── AutomationResources
│       │   ├── Data
│       │   ├── Models
│       │   ├── Tests
│       │   └── Utilities/
│       │       ├── ExtentReports
│       │       └── Listeners
│       └── resources
└── target

Setup 🛠️

I developed the code using a Mac, but it should work on a PC.

The following steps can be executed using the terminal and UI of IntelliJ.

  1. Clone the repo.-
> https://github.com/ArCiGo/Java-Automation-Framework.git

> git checkout SampleProject_1
  1. Once you cloned the repo, look for the pom.xml file, at root, right click over the file, select maven option and then click on Download Sources or Download Sources and Documentation.

Run the tests ⚡️

  1. Look for the testng.xml file at src/ => test/ => resources/, right click over the file and click on Run.

When you execute the tests, new folders are generated at the workspace root (extent-reports). Inside of this folder, you are going to see the index.html report (you can open them using your favorite browser). Also, new log files are generated and you can open them using any text editor.

UI Report Sample 2

Log Report Sample

UI Report Sample 1

About

Java Automation Framework template to create new projects

Resources

Stars

Watchers

Forks