A small Python exercise for practising unit testing and CI/CD.
DaysLeftInYear.py exposes one function:
days_left_in_year(today: date | None = None) -> int
It returns the number of days remaining in the year after today,
defaulting to the current date. December 31st returns 0.
python3 DaysLeftInYear.py # print the days left today
python3 -m unittest -v # run the test suite
.github/workflows/tests.yml runs the test suite on every push and
pull request, against Python 3.10, 3.11 and 3.12.
Requires Python 3.10 or newer (the date | None type hint syntax).