-> The purpose of the project was to practice converting test cases to automata using Selenium and Pytest while using OOP to write readable and clean code. After the tests are performed HTML, log, and screenshots files are produced automatically (Screenshots will be taken only when a test failed from the section that failed for follow-up).
- The project run on a local Jenkin server, which I can easily manage without using an IDE or CMD (optional).
- Selenium
- WebDriver
- Pytest
- OpenPyXL
- Logging
- Inspect
-
PageObjects -> hold a Class for each page on the website, helps us to get elements from each page.
- CheckoutPage.py
- ConfirmPage.py
- HomePage.py
-
Reports -> The HTML report from the tests produce here.
- report.html
-
Tests -> All test cases are divided into files according to tests for pages and E2E.
- test_CheckoutPage.py
- test_HomePage.py
- test_E2E
- screenshots
- conftest.py (instead of copying code lines necessary for each test, with Pytest fixture I'm doing that once and using in class utilities.Setup for reusable purposes)
-
TestsData -> holding an xlsx file with data and parameters for each test and class with a method to extract the data for each test. -testsData.py -TestsData.xlsx
-
Utilites ->
- Setup.py - a reusable class that hold reuseable methods, logger, and default setttings for each test.
- logfile.log
- download drivers Chromedriver(Chrome), Geckodriver(Firefox), and msedgedriver(EdgeDriver)
- install all mention above libararies.
- Make sure all path in files are updated according to your computer