@@ -35,17 +35,21 @@ const page = await context.newPage()
3535const errors = [ ]
3636page . on ( 'pageerror' , ( err ) => errors . push ( String ( err ) ) )
3737
38- await page . goto ( `${ BASE_URL } /settings` , { waitUntil : 'networkidle ' , timeout : 60000 } )
39- await page . waitForTimeout ( 2000 )
38+ await page . goto ( `${ BASE_URL } /settings` , { waitUntil : 'domcontentloaded ' , timeout : 60000 } )
39+ await page . waitForTimeout ( 3000 )
4040
4141const bodyText = await page . locator ( 'body' ) . innerText ( )
4242const hasHint = bodyText . includes ( 'voice character notes' ) || bodyText . includes ( 'Voice character notes' )
4343const hasBackend = bodyText . includes ( 'Voice backend' ) || bodyText . includes ( 'Gemini Live' )
4444
45- // Open voice picker
46- const voiceRow = page . getByRole ( 'button' , { name : / ^ V o i c e \b / i } ) . first ( )
47- await voiceRow . click ( { timeout : 15000 } ) . catch ( ( ) => { } )
48- await page . waitForTimeout ( 500 )
45+ // Open voice picker (trigger shows Voice label + current value on the right)
46+ const voicePicker = page . locator ( 'button[aria-haspopup="listbox"]' ) . filter ( { hasText : / ^ V o i c e $ / } ) . first ( )
47+ if ( await voicePicker . count ( ) === 0 ) {
48+ await page . getByRole ( 'button' , { name : / V o i c e \s + / } ) . first ( ) . click ( { timeout : 15000 } ) . catch ( ( ) => { } )
49+ } else {
50+ await voicePicker . click ( { timeout : 15000 } )
51+ }
52+ await page . waitForTimeout ( 800 )
4953
5054const afterOpen = await page . locator ( 'body' ) . innerText ( )
5155const hasDescription = afterOpen . includes ( 'Conversational, friendly' )
0 commit comments