Context
The Honeygain collector (app/collectors/honeygain.py) authenticates via JWT. When the JWT expires mid-collection, the collector should handle it gracefully.
Task
- Write a test in
tests/test_collectors.py that mocks an expired JWT response (401) from the Honeygain API
- Verify the collector returns a sensible error value (not a crash)
- Verify logs include a clear message about auth failure
Reference
app/collectors/honeygain.py — current implementation
app/collectors/base.py — BaseCollector interface