-
Clone the repository:
git clone https://github.com/your_username/your_repository.git
-
Install the required dependencies:
pip install -r requirements.txt
-
To run the FastAPI application locally, use the following command:
uvicorn main:app --reload
You can access the application at http://localhost:8000/ or the docs http://localhost:8000/docs. It provides the following endpoints:
/ - Renders the index.html template.
/python - Retrieves a random Python response from a predefined list.
/reverse/{name} - Reverses the provided name and returns the letter count along with the reversed name.
- To run the unit tests using PyTest, execute the following command:
pytest