Skip to content

Add pytest suite and gate Docker publishing - #16

Merged
Skulldorom merged 1 commit into
mainfrom
hermes/add-ci-tests
Jul 20, 2026
Merged

Add pytest suite and gate Docker publishing#16
Skulldorom merged 1 commit into
mainfrom
hermes/add-ci-tests

Conversation

@Skulldorom

Copy link
Copy Markdown
Owner

Summary

  • Add a pytest suite covering FreshRSS env validation, health endpoint behavior, token login/caching failures, unread feed shaping, category scoping, missing timestamps/URLs, and upstream request failures.
  • Gate Docker publishing behind a required test job in GitHub Actions.
  • Run tests on pull requests, while only building/pushing GHCR images for pushes to main after tests pass.
  • Document local test commands and exclude tests/ from the Docker build context.

Validation

  • uv sync --frozen && uv run pytest -q9 passed in 0.22s
  • README/workflow sanity check → README and workflow sanity checks passed
  • docker build --progress=plain -t rss-api-test-gate . → passed, image built as rss-api-test-gate

Notes

The tests exposed and fixed a few real edge cases while being added:

  • FreshRSS login request exceptions now return a 502 instead of bubbling raw requests exceptions.
  • FreshRSS unread request exceptions now return a 502 instead of bubbling raw upstream errors.
  • Empty/missing alternate arrays no longer raise IndexError.
  • Direct unit calls no longer treat FastAPI's Query(...) default object as a category label.

@Skulldorom
Skulldorom marked this pull request as ready for review July 20, 2026 09:10
@Skulldorom
Skulldorom merged commit 8548e7e into main Jul 20, 2026
2 checks passed
@Skulldorom
Skulldorom deleted the hermes/add-ci-tests branch July 20, 2026 09:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant