Add pytest with a /health test and GitHub Actions CI
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 90/100
Research direction
Start with the FastAPI app entry point and the actions/setup-python starter workflow, then create backend/tests/test_health.py, backend/requirements-dev.txt, and .github/workflows/ci.yml as described. Use FastAPI's TestClient to exercise /health without a database. Done means pytest passes locally and GitHub Actions runs it on every pull request with a green check.
Written by the indexing model from the issue text.
Description
Why
Every PR should prove it didn't break the app. This issue sets up the testing and CI pattern that everyone else will copy.
Files to touch
backend/tests/test_health.py(new)backend/requirements-dev.txt(new) or addpytest+httpxtorequirements.txt.github/workflows/ci.yml(new)
Definition of done
-
pytestpasses locally with one test hitting/healthvia FastAPI'sTestClient - A GitHub Actions workflow runs
pyteston every pull request - The workflow shows a green check on this PR
Hints
No database is needed yet since /health doesn't touch Postgres. Start from the actions/setup-python starter workflow. FastAPI testing docs: https://fastapi.tiangolo.com/tutorial/testing/
- Dominant language
- JavaScript
- Stars
- 2
- Forks
- 2
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from WSU-Software-Development-Club/self-hosting
-
intermediate
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
-
good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
-
good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
advanced
Difficulty 4/5 3-5 days Newbie friendliness 65/100
-
intermediate
Difficulty 4/5 3-5 days Newbie friendliness 58/100
All issues in WSU-Software-Development-Club/self-hosting
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
HarperFast/skills#96 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Automattic/studio#4908 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
sugarlabs/musicblocks#8847 ·
-
client-controller-update ta-bot-triage team-money-movement
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
MetaMask/metamask-mobile#36594 ·