E2E Test: basic tests.#641
Open
cloudwebrtc wants to merge 4 commits intomainfrom
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds an end-to-end test (
test_connection_basics) tolivekit-rtc/tests/test_basic.py. The test exercises the full connect/disconnect/reconnect lifecycle and track publish/subscribe flow across fourrtc.Roominstances against a live LiveKit server.What the test covers
Four participants (
p1–p4) join a uniquely-named room, then walk through:p1andp2connect; both reachCONN_CONNECTED.p1disconnects;p2receivesparticipant_disconnectedforp1.p1thenp2reachCONN_DISCONNECTED.p3joins → disconnects → reconnects with the same token → disconnects, assertingconnection_stateafter each step.p4joins,p3reconnects, then publishes a camera track and a mic track.p4receivestrack_publishedfor each (the audio future filters by SID so the prior video event doesn't satisfy it) and subscribes to both.p3andp4disconnect cleanly.Requirements
LIVEKIT_URL).LIVEKIT_API_KEY/LIVEKIT_API_SECRETfor token minting.pytest+pytest-asyncio(test is@pytest.mark.asyncio).Test plan
pytest livekit-rtc/tests/test_basic.pyagainst a local or staging LiveKit deployment with all three env vars set — expect a single passing test.