https://github.com/asif-shahriar/pytest-web-automation
Web automation project of Selenium Pytest using Page Object Model
https://github.com/asif-shahriar/pytest-web-automation
allure-report page-object-model pytest python selenium
Last synced: about 1 month ago
JSON representation
Web automation project of Selenium Pytest using Page Object Model
- Host: GitHub
- URL: https://github.com/asif-shahriar/pytest-web-automation
- Owner: asif-shahriar
- Created: 2023-10-23T06:42:35.000Z (almost 2 years ago)
- Default Branch: master
- Last Pushed: 2023-10-29T08:16:36.000Z (almost 2 years ago)
- Last Synced: 2025-06-09T06:46:34.839Z (4 months ago)
- Topics: allure-report, page-object-model, pytest, python, selenium
- Language: Python
- Homepage: https://demo.nopcommerce.com
- Size: 15.6 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Web automation using Pytest Selenium
## Prerequisites
* Install **Python** and **PyCharm** in your local device
* Clone the project
* Open terminal in the root folder and run the following command:
```
pip install -r prerequisites.txt
```
* Copy the absloute path of [this json file](https://github.com/asif-shahriar/Pytest-Web_Automation/blob/master/json_factory/registration.json "registration.json") and paste them in [Registration.py > registration_json_directory](https://github.com/asif-shahriar/Pytest-Web_Automation/blob/master/testcases/Registration.py "Registration.py") and also in [Test Run 2.py > registration_directory](https://github.com/asif-shahriar/Pytest-Web_Automation/blob/master/runner/Test_Run2.py "Test_Run2.py"). The directory should look like this: **"D:\\\Your Folder name\\\json_factory\\\registration.json"**## How to run this project
* Open terminal in the root folder
* Run the following set of commands:
```
python -m pytest runner -vv -s --alluredir=allure-results --clean-alluredir
```
```
allure serve allure-results
```
* **Optional:** If you want to run only the **smoke/regression** test cases, run either of the follwing set of commands:
```
python -m pytest -m smoke runner -vv -s --alluredir=allure-results --clean-alluredir
```
```
allure serve allure-results
```
* OR,```
python -m pytest -m regression runner -vv -s --alluredir=allure-results --clean-alluredir
```
```
allure serve allure-results
```
## Allure Report Screenshot
