هذا الالتزام موجود في:
18
README.md
18
README.md
@@ -17,6 +17,8 @@ fruit-api/
|
||||
│── fruit_api.log # API logs
|
||||
│── README.md # Documentation
|
||||
│── .gitignore # Ignore venv/logs
|
||||
│── .github/workflows/ci.yml # CI workflow for testing
|
||||
|
||||
```
|
||||
|
||||
## 📌 Features
|
||||
@@ -28,6 +30,8 @@ fruit-api/
|
||||
- Bash script for monitoring logs (`log_monitor.sh`) with **error alerts (4xx/5xx)**
|
||||
- Bash script for automated API testing (`test_api.sh`) with ✅ / ❌ results
|
||||
- Swagger/OpenAPI documentation at `/docs`
|
||||
- `CI/CD` pipeline for automated testing
|
||||
|
||||
|
||||
---
|
||||
|
||||
@@ -163,6 +167,20 @@ After starting the API, open:
|
||||
|
||||
---
|
||||
|
||||
## ⚡ CI/CD Pipeline
|
||||
|
||||
This project uses **Continuous Integration (CI)** to ensure the API works correctly after every code change.
|
||||
|
||||
### Workflow
|
||||
- Triggered on every **push** or **pull request** to `main` branch.
|
||||
- Installs dependencies (`requirements.txt`).
|
||||
- Starts the API in the background.
|
||||
- Runs automated tests (`test_api.sh`).
|
||||
- Pipeline **fails** if any test ❌ fails.
|
||||
|
||||
---
|
||||
|
||||
|
||||
## 🐳 Docker Support
|
||||
|
||||
### Build the image
|
||||
|
المرجع في مشكلة جديدة
حظر مستخدم