https://github.com/codewithmmak/rest-api-requests-python
RESTful API Testing in Python with requests
https://github.com/codewithmmak/rest-api-requests-python
api api-automation api-testing-framework pytest pytest-bdd pytest-html python requests restful-api test-automation
Last synced: 5 months ago
JSON representation
RESTful API Testing in Python with requests
- Host: GitHub
- URL: https://github.com/codewithmmak/rest-api-requests-python
- Owner: codewithmmak
- License: mit
- Created: 2021-04-03T14:41:26.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2022-12-24T18:00:16.000Z (about 3 years ago)
- Last Synced: 2023-03-04T02:19:36.629Z (almost 3 years ago)
- Topics: api, api-automation, api-testing-framework, pytest, pytest-bdd, pytest-html, python, requests, restful-api, test-automation
- Language: Python
- Homepage:
- Size: 75.2 KB
- Stars: 4
- Watchers: 1
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# RESTful API Testing in Python with requests
## To Get Started
### Pre-requisites
* Download and install Python:
* [Install Python](https://www.python.org/downloads/ "Install Python")
* Download and install any Text Editor like Visual Code/Sublime/Brackets
* [Install Visual Studio Code](https://code.visualstudio.com/download "Install Visual Studio Code")
### Setup
* Clone the repository into a folder
* Go to Project root directory and install Dependency: `pip install -r requirements.txt`
* All the dependencies from requirements.txt will be installed.
### Run Test
1. Open Terminal
2. Go to project location
3. Enter `pytest` and hit enter key
### Capture stdout
1. Open Terminal
2. Go to project location
3. Enter `pytest -sv --capture=sys` and hit enter key
### Generate HTML Report using pytest-html
1. Open Terminal
2. Go to project location
3. Enter `pytest -sv --capture=sys --html=report.html` and hit enter key
#### HTML Report
