Small object-oriented fitness tracker example project.
src/— application source codetests/— pytest test suitedata.json— persistent data file (project root)
Install the test runner (used only for running tests):
pip install -r requirements.txt
requirements.txtcurrently containspytestfor running tests.
From the project root run:
python src/main.pyThis prints sample output and writes to data.json at project root.
From the project root run:
python -m pytest -qRepositorywrites todata.jsonat the project root to avoid creating multiple files when running from different CWDs.- You can extend models, add CLI options to
src/main.py, or add CI (GitHub Actions) for automated tests.