-
Notifications
You must be signed in to change notification settings - Fork 31
Open
Description
Hi maintainers
The MUIO Flask backend currently does not have an automated testing suite. This makes it harder to confidently refactor code, verify endpoint behavior, and maintain long-term reliability as the project evolves.
Proposed Changes
-
Add pytest and pytest-flask as development dependencies
-
Create a structured test directory:
tests/
├── conftest.py
└── test_app.py -
Implement reusable Flask test client fixtures that run the app in TESTING mode without starting the Waitress server
-
Add initial unit tests for core endpoints in
API/app.py, including:- GET / → verify index is served successfully
- GET /getSession → validate behavior when session is missing
- POST /setSession → verify valid session persistence flow
- POST /setSession (invalid payload) → validate error handling
Expected Benefits
- Improves backend reliability
- Enables safer future refactoring
- Provides a foundation for expanding test coverage
- Aligns the project with modern testing best practices
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels