Add signal tests to test-server#4653
Conversation
boks1971
left a comment
There was a problem hiding this comment.
I think signal test is fine.
|
|
||
| func isValidatePath(path string) bool { | ||
| return path == "/rtc/validate" || path == "/rtc/v1/validate" | ||
| } |
There was a problem hiding this comment.
maybe these can use helpers from pkg/service/utils.go. Would be good to have it all in one place for these paths.
There was a problem hiding this comment.
main reason I didn't do it from the start was that the mock currently doesn't depend on the rtc package and we'd be pulling in a bunch of dependencies "just" for the helpers.
Generally agree though that it would be nicer if they were reused.
I'll change it to reuse them from service/utils.go. Let me know if I should extract those helpers into their own package that doesn't pull in the rtc deps
There was a problem hiding this comment.
It is okay to leave this as strings for now. Yeah, don't want to grow the dependency tree. We can address this later.
…3 ➔ v1.13.4) (#1641) This PR contains the following updates: | Package | Update | Change | |---|---|---| | [docker.io/livekit/livekit-server](https://github.com/livekit/livekit) | patch | `v1.13.3` → `v1.13.4` | --- ### Release Notes <details> <summary>livekit/livekit (docker.io/livekit/livekit-server)</summary> ### [`v1.13.4`](https://github.com/livekit/livekit/releases/tag/v1.13.4) [Compare Source](livekit/livekit@v1.13.3...v1.13.4) ##### Added - added mocking function for SIP dialing methods ([#​4642](livekit/livekit#4642)) - Add signal tests to test-server ([#​4653](livekit/livekit#4653)) - Add option to exclude local IPv6 candidates. ([#​4657](livekit/livekit#4657)) - Add a method to get forward stats via API method. ([#​4664](livekit/livekit#4664)) - Add drop-on-close signal test scenario ([#​4669](livekit/livekit#4669)) - Log soft validation errors. ([#​4671](livekit/livekit#4671)) - add redaction flag in Job ([#​4650](livekit/livekit#4650)) ##### Changed - simpler mock protocol ([#​4641](livekit/livekit#4641)) - Make IsConnectionCanceled available at LocalParticipant interface. ([#​4643](livekit/livekit#4643)) - Update actions/checkout action to v7 ([#​4646](livekit/livekit#4646)) - Update protocol. ([#​4648](livekit/livekit#4648)) - Export migration to LocalParticipant interface. ([#​4652](livekit/livekit#4652)) - Record final RTC state as success/failure. ([#​4658](livekit/livekit#4658)) - Omit rtx/out-of-order packets from forwarding delay measurement. ([#​4659](livekit/livekit#4659)) - Move ForwardStats aggregation off the packet forwarding path ([#​4660](livekit/livekit#4660)) - protocol deps to get parallel exec alloc reduction ([#​4662](livekit/livekit#4662)) - Update pion/ice to deal with hang on close. ([#​4672](livekit/livekit#4672)) - Add more details to unreliable data channel drop error. ([#​4673](livekit/livekit#4673)) - Record `rtc_success` prom as soon as RTC connects. ([#​4677](livekit/livekit#4677)) - Use proto logger to get named enums in the logs. ([#​4679](livekit/livekit#4679)) - Propagate spreader threshold to RED receivers. ([#​4683](livekit/livekit#4683)) - Prefer QDisc.Stats till go-tc addresses QDisc.Stats2 parsing ([#​4685](livekit/livekit#4685)) - Bump protocol version to fix call to Validate. ([#​4686](livekit/livekit#4686)) ##### Fixed - bound data-track buffering under downlink congestion (targetLatency) ([#​4667](livekit/livekit#4667)) - Guard against nil TC qdisc stats to prevent SIGSEGV ([#​4668](livekit/livekit#4668)) - Fix goroutine leak from orphaned signal relay streams ([#​4674](livekit/livekit#4674)) - don't undercount data channel bitrate over idle gaps ([#​4676](livekit/livekit#4676)) - Fix receiver load balance threshold initialization ([#​4678](livekit/livekit#4678)) - rtc: guard against nil subscriber in TransportManager.HandleAnswer ([#​4680](livekit/livekit#4680)) - Potential fix for code scanning alert no. 42: Incorrect conversion between integer types ([#​4684](livekit/livekit#4684)) </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about these updates again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0My4xMDEuMSIsInVwZGF0ZWRJblZlciI6IjQzLjEwMS4xIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJyZW5vdmF0ZS9jb250YWluZXIiLCJ0eXBlL3BhdGNoIl19--> Reviewed-on: https://git.erwanleboucher.dev/eleboucher/homelab/pulls/1641
Note
closely guided LLM output ahead
Allows for clients to test signal specific connection paths and failures against the test-server. Participant attribute with key
lk.mockdecides on which path to take.Let me know if there are any scenarios missing that might be worth adding.
Not sure if the signal_test.go file is particularly useful, happy to remove if you think there's no additional value in there.