M4: Forgejo CI workflow + browser WHEP player + TESTING.md #8

Closed
zgaetano wants to merge 0 commits from m4-ci-and-tooling into m2-webrtc-core-integration
Owner

First half of M4: CI infrastructure + manual smoke testing. The latency p95 gate is queued for a separate PR (a multi-hundred-line addition by itself).

.forgejo/workflows/test.yml

Three jobs, GitHub Actions syntax (Forgejo Actions accepts it as-is):

Job What Why a separate job
lint-and-vet go vet + go build Fast feedback (~30s) before the slow tests start
test go test -race -short -count=1 ./... plus a no-race coverage pass that uploads coverage.out as a 14-day artifact Race detector and coverage in one run is meaningfully slower; the artifact lets future regressions diff against a known good baseline
webrtc-smoke TestIntegration_* and the WebRTC handler tests in isolation A failure on the egress path stays readable in the actions log instead of being buried among ~80 packages of unrelated Core tests

Pinned to Go 1.24 to match go.mod. Triggered on push to main / m* / fix/** and on every pull request.

test/whep-player.html

Self-contained browser WHEP subscriber. No external deps, works from file:// or any static host.

  • RTCPeerConnection with addTransceiver('video'|'audio', { direction: 'recvonly' })
  • POSTs the offer to a configurable WHEP URL with optional Bearer JWT
  • Renders the resulting MediaStream in <video>
  • ICE/PC state pills, codec hint pulled from the answer SDP, 1-Hz inbound-bitrate sample via getStats()
  • WHEP-spec DELETE on disconnect using the resource URL the server returned in Location
  • Shareable query string: ?url=…&token=…

test/TESTING.md

Short doc that ties together the three smoke surfaces — in-process race tests, browser player, Pion CLI helper — with copy-pasteable commands. Notes the latency gate as a known follow-up.

Why land this without the latency gate

The CI workflow is the highest-leverage piece of M4 — every subsequent PR benefits from the race + integration-test pass-fail signal. The browser player closes a real verification gap (acceptance criterion #4 from the M2 design says the user can watch live video; until now there was no off-the-shelf way to do that without the unfinished core-ui work). The latency gate is well-scoped but big; carving it into its own PR keeps review surface small.

Stacks on m2-webrtc-core-integration so it lands without depending on M3 (#5), the issue-#2 fix (#6), or the issue-#3 fix (#7).

Co-authored with Claude Opus 4.7.

First half of M4: CI infrastructure + manual smoke testing. The latency p95 gate is queued for a separate PR (a multi-hundred-line addition by itself). ## .forgejo/workflows/test.yml Three jobs, GitHub Actions syntax (Forgejo Actions accepts it as-is): | Job | What | Why a separate job | | ---- | ---- | --- | | `lint-and-vet` | `go vet` + `go build` | Fast feedback (~30s) before the slow tests start | | `test` | `go test -race -short -count=1 ./...` plus a no-race coverage pass that uploads `coverage.out` as a 14-day artifact | Race detector and coverage in one run is meaningfully slower; the artifact lets future regressions diff against a known good baseline | | `webrtc-smoke` | `TestIntegration_*` and the WebRTC handler tests in isolation | A failure on the egress path stays readable in the actions log instead of being buried among ~80 packages of unrelated Core tests | Pinned to Go 1.24 to match `go.mod`. Triggered on push to `main` / `m*` / `fix/**` and on every pull request. ## test/whep-player.html Self-contained browser WHEP subscriber. No external deps, works from `file://` or any static host. - `RTCPeerConnection` with `addTransceiver('video'|'audio', { direction: 'recvonly' })` - POSTs the offer to a configurable WHEP URL with optional Bearer JWT - Renders the resulting MediaStream in `<video>` - ICE/PC state pills, codec hint pulled from the answer SDP, 1-Hz inbound-bitrate sample via `getStats()` - WHEP-spec DELETE on disconnect using the resource URL the server returned in `Location` - Shareable query string: `?url=…&token=…` ## test/TESTING.md Short doc that ties together the three smoke surfaces — in-process race tests, browser player, Pion CLI helper — with copy-pasteable commands. Notes the latency gate as a known follow-up. ## Why land this without the latency gate The CI workflow is the highest-leverage piece of M4 — every subsequent PR benefits from the race + integration-test pass-fail signal. The browser player closes a real verification gap (acceptance criterion #4 from the M2 design says the user can watch live video; until now there was no off-the-shelf way to do that without the unfinished core-ui work). The latency gate is well-scoped but big; carving it into its own PR keeps review surface small. Stacks on `m2-webrtc-core-integration` so it lands without depending on M3 (#5), the issue-#2 fix (#6), or the issue-#3 fix (#7). Co-authored with Claude Opus 4.7.
zgaetano added 1 commit 2026-05-03 08:15:10 -04:00
ci+test: forgejo workflow, browser WHEP player, TESTING.md (M4 part 1)
Some checks failed
ci / vet + build (push) Successful in 9m50s
ci / vet + build (pull_request) Successful in 9m49s
ci / race tests (push) Failing after 8m4s
ci / WebRTC smoke (5-viewer fanout) (push) Successful in 9m48s
ci / race tests (pull_request) Failing after 6m28s
ci / WebRTC smoke (5-viewer fanout) (pull_request) Successful in 9m46s
927ccc6ced
Three artifacts that close out the easier half of the M4 milestone:

1. .forgejo/workflows/test.yml — CI on every push and PR. Three jobs:
     - lint-and-vet: go vet + go build (~30s)
     - test:        go test -race -short ./... + a no-race coverage
                    pass that uploads coverage.out as an artifact
     - webrtc-smoke: TestIntegration_FiveViewerFanout and the rest of
                     the WebRTC subsystem tests in isolation, so a
                     failure on the egress path stays readable in the
                     log.
   Pinned to Go 1.24 to match go.mod. The forge has a
   forgejo-runner sibling container; this YAML uses GitHub Actions
   syntax which Forgejo Actions accepts unchanged.

2. test/whep-player.html — self-contained browser WHEP subscriber for
   manual smoke testing. RTCPeerConnection (recvonly V+A) + fetch()
   POST/DELETE/PATCH against /api/v3/whep/:id, ICE/PC state pills,
   inbound-bitrate sampling at 1 Hz, codec hint pulled from the answer
   SDP, JWT token field, ?url=&token= shareable query string. No
   external deps; works from file:// or any static host.

3. test/TESTING.md — short doc that ties together the in-process race
   tests, the browser player, and the existing Pion CLI helper at
   test/whep-client/. Notes the latency p95 gate as a follow-up.

Latency gate (FFmpeg drawtext frame counter + decode-side pixel
sampling, p95 < 300ms RTMP / < 200ms SRT) is queued for a separate
PR — it's a several-hundred-line addition in its own right and
shouldn't block CI from landing.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Author
Owner

Merged into main via direct push as part of the v0.1.0-dragonfork release. Branch commits are reachable from main; closing this PR. Release: https://forge.wilddragon.net/zgaetano/datarhei-dragonfork-core/releases/tag/v0.1.0-dragonfork

Merged into `main` via direct push as part of the v0.1.0-dragonfork release. Branch commits are reachable from main; closing this PR. Release: https://forge.wilddragon.net/zgaetano/datarhei-dragonfork-core/releases/tag/v0.1.0-dragonfork
zgaetano closed this pull request 2026-05-03 08:28:58 -04:00
Some checks failed
ci / vet + build (push) Successful in 9m50s
ci / vet + build (pull_request) Successful in 9m49s
ci / race tests (push) Failing after 8m4s
ci / WebRTC smoke (5-viewer fanout) (push) Successful in 9m48s
ci / race tests (pull_request) Failing after 6m28s
ci / WebRTC smoke (5-viewer fanout) (pull_request) Successful in 9m46s

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: zgaetano/datarhei-dragonfork-core#8
No description provided.