11import { expect , test } from './helpers/fixtures' ;
22
33test . describe ( 'start session' , ( ) => {
4- // test.beforeAll(async ({ page }) => {
5- // // Set disclaimer as accepted for persistence across tests
6- // await page.addInitScript(() => {
7- // localStorage.setItem('app', JSON.stringify({ state: { isDisclaimerAccepted: true }, version: 1 }));
8- // });
9- // });
10-
114 test ( 'should display the start session form header' , async ( { getPageModel } ) => {
125 const startSessionPage = await getPageModel ( '/session/start-session' ) ;
136 await expect ( startSessionPage . pageHeader ) . toBeVisible ( ) ;
@@ -19,20 +12,9 @@ test.describe('start session', () => {
1912 const startSessionPage = await getPageModel ( '/session/start-session' ) ;
2013
2114 await startSessionPage . sessionForm . waitFor ( { state : 'visible' } ) ;
22- const formType = startSessionPage . sessionForm . getByTestId ( 'subjectIdentificationMethod-select-trigger' ) ;
23- await formType . click ( ) ;
24-
2515 await startSessionPage . selectIdentificationMethod ( 'PERSONAL_INFO' ) ;
2616
27- // await startSessionPage.selectIdentificationMethod('Personal Information')
28- await expect ( formType ) . toHaveText ( 'Personal Information' ) ;
29-
30- // const identifier = startSessionPage.sessionForm.locator('#subjectFirstName');
31- // await identifier.fill('john')
32- // await expect(identifier).toHaveText('john');
33- // await startSessionPage.fillSessionForm('john')
34-
35- // await startSessionPage.sessionForm.fill('John');
36- // await expect(startSessionPage.sessionForm).toHaveValue('John');
17+ // Verify the selection was made
18+ await expect ( startSessionPage . selectField ) . toHaveValue ( 'PERSONAL_INFO' ) ;
3719 } ) ;
3820} ) ;
0 commit comments