remove a participant
(t *testing.T)
| 88 | |
| 89 | // remove a participant |
| 90 | func TestMultiNodeRemoveParticipant(t *testing.T) { |
| 91 | if testing.Short() { |
| 92 | t.SkipNow() |
| 93 | return |
| 94 | } |
| 95 | |
| 96 | for _, testRTCServicePath := range testRTCServicePaths { |
| 97 | t.Run(fmt.Sprintf("testRTCServicePath=%s", testRTCServicePath.String()), func(t *testing.T) { |
| 98 | _, _, finish := setupMultiNodeTest("TestMultiNodeRemoveParticipant") |
| 99 | defer finish() |
| 100 | |
| 101 | c1 := createRTCClient("mn_remove_participant", defaultServerPort, testRTCServicePath, nil) |
| 102 | defer c1.Stop() |
| 103 | waitUntilConnected(t, c1) |
| 104 | |
| 105 | ctx := contextWithToken(adminRoomToken(testRoom)) |
| 106 | _, err := roomClient.RemoveParticipant(ctx, &livekit.RoomParticipantIdentity{ |
| 107 | Room: testRoom, |
| 108 | Identity: "mn_remove_participant", |
| 109 | }) |
| 110 | require.NoError(t, err) |
| 111 | |
| 112 | // participant list doesn't show the participant |
| 113 | listRes, err := roomClient.ListParticipants(ctx, &livekit.ListParticipantsRequest{ |
| 114 | Room: testRoom, |
| 115 | }) |
| 116 | require.NoError(t, err) |
| 117 | require.Len(t, listRes.Participants, 0) |
| 118 | }) |
| 119 | } |
| 120 | } |
| 121 | |
| 122 | // update participant metadata |
| 123 | func TestMultiNodeUpdateParticipantMetadata(t *testing.T) { |
nothing calls this directly
no test coverage detected