• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

rm-hull / next-departures-api / 25230342317
28%

Build:
DEFAULT BRANCH: main
Ran 01 May 2026 07:51PM UTC
Jobs 1
Files 16
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

01 May 2026 07:50PM UTC coverage: 22.073% (+5.4%) from 16.632%
25230342317

push

github

web-flow
feat: handle SIRI rate limits and add route tests (#8)

*   Implemented handling for SIRI API "Usage limits exceeded" errors by
    returning **429 Too Many Requests**.
*   Added `Retry-After` and `X-RateLimit-Reset` headers calculated based
    on the duration until midnight.
*   Refactored `SiriClient` into an interface to facilitate mocking and
    improved testability.
*   Introduced comprehensive unit tests for the `NextDepartures` route
    covering success, rate-limiting, and error scenarios.

```mermaid
sequenceDiagram
    participant User
    participant Route as NextDepartures Route
    participant Client as SiriClient (Mock/Impl)
    User->>Route: Request departures for stopId
    Route->>Client: GetStopMonitoring(stopId)
    alt Rate Limited
        Client-->>Route: 403 Forbidden (Usage limits exceeded)
        Route-->>User: 429 Too Many Requests + Retry-After headers
    else Success
        Client-->>Route: 200 OK + Siri Data
        Route-->>User: 200 OK + Formatted Results
    end
```

---------

Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>

10 of 13 new or added lines in 2 files covered. (76.92%)

213 of 965 relevant lines covered (22.07%)

0.24 hits per line

Uncovered Changes

Lines Coverage ∆ File
3
0.0
0.0% internal/siri_client.go
Jobs
ID Job ID Ran Files Coverage
1 25230342317.1 01 May 2026 07:51PM UTC 16
22.07
GitHub Action Run
Source Files on build 25230342317
  • Tree
  • List 16
  • Changed 2
  • Source Changed 0
  • Coverage Changed 2
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • d2b7e3db on github
  • Prev Build on main (#25151801903)
  • Next Build on main (#25232538890)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc