@@ -9,7 +9,7 @@ import { Browser, expect, type Page, test } from "@playwright/test";
9
9
// npx playwright test --project=local --repeat-each 15 --grep "chromium_chromium disconnect and reconnect"
10
10
11
11
const PULSEBEAM_BASE_URL = process . env . PULSEBEAM_BASE_URL ||
12
- "https://cloud.pulsebeam.dev/twirp " ;
12
+ "https://cloud.pulsebeam.dev/grpc " ;
13
13
14
14
async function waitForStableVideo (
15
15
page : Page ,
@@ -46,20 +46,20 @@ async function waitForStableVideo(
46
46
throw new Error ( "waitForStableVideo timeout" ) ;
47
47
}
48
48
49
- async function start ( page : Page , peerId : string ) {
49
+ async function start ( page : Page , peerId : string ) {
50
50
await page . getByTestId ( "src-peerId" ) . fill ( peerId ) ;
51
51
await waitForStableVideo ( page , peerId , 5_000 ) ;
52
-
52
+
53
53
await page . getByTestId ( "btn-ready" ) . click ( ) ;
54
-
54
+
55
55
return ( ) => page . getByTestId ( "btn-endCall" ) . click ( ) ;
56
56
}
57
57
58
58
async function connect ( page : Page , peerId : string , otherPeerId : string ) {
59
- start ( page , peerId )
59
+ start ( page , peerId ) ;
60
60
await page . getByTestId ( "dst-peerId" ) . fill ( otherPeerId ) ;
61
61
await page . getByTestId ( "btn-connect" ) . click ( ) ;
62
- await expect ( page . getByTestId ( "btn-connect" ) ) . not . toBeVisible ( )
62
+ await expect ( page . getByTestId ( "btn-connect" ) ) . not . toBeVisible ( ) ;
63
63
await waitForStableVideo ( page , otherPeerId , 10_000 ) ;
64
64
65
65
return ( ) => page . getByTestId ( "btn-endCall" ) . click ( ) ;
@@ -210,8 +210,8 @@ test.describe("Connect", () => {
210
210
211
211
// Attempt simultaneous connection
212
212
await Promise . all ( [
213
- pageA . getByTestId ( "btn-connect" ) . click ( ) . catch ( ( ) => { } ) ,
214
- pageB . getByTestId ( "btn-connect" ) . click ( ) . catch ( ( ) => { } ) ,
213
+ pageA . getByTestId ( "btn-connect" ) . click ( ) . catch ( ( ) => { } ) ,
214
+ pageB . getByTestId ( "btn-connect" ) . click ( ) . catch ( ( ) => { } ) ,
215
215
] ) ;
216
216
217
217
// Verify buttons are hidden
@@ -221,13 +221,13 @@ test.describe("Connect", () => {
221
221
] ) ;
222
222
223
223
await waitForStableVideo ( pageA , peerB , 10_000 ) ,
224
- await waitForStableVideo ( pageB , peerA , 10_000 ) ,
225
-
226
- await Promise . all ( [ closeA ( ) , closeB ( ) ] ) ;
224
+ await waitForStableVideo ( pageB , peerA , 10_000 ) ,
225
+ await Promise . all ( [ closeA ( ) , closeB ( ) ] ) ;
227
226
} finally {
228
227
await contextA . close ( ) ;
229
228
await contextB . close ( ) ;
230
229
}
231
230
} ) ;
232
231
}
233
- } ) ;
232
+ } ) ;
233
+
0 commit comments