Skip to content

Commit 3b30c56

Browse files
test(registration): add test for terms of use before registration
This commit implements TC-1621 to ensure users are properly informed about the terms of use when creating a personal account via the SSO login flow. The implemented scenario verifies: - Entering an unregistered email on the SSO sign-in page. - Navigating to the personal account registration page. - The visibility of the Terms of Use link. - Opening the link and validating the correct routing to the `/legal#terms` URL in a new tab. Refs: WPB-24831
1 parent a087147 commit 3b30c56

1 file changed

Lines changed: 24 additions & 0 deletions

File tree

apps/webapp/test/e2e_tests/specs/Registration/registration.spec.ts

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,30 @@ test.describe('Registration', () => {
3232
addCreatedUser(userA);
3333
});
3434

35+
test(
36+
'I want to be informed about terms of personal account before registration',
37+
{tag: ['@TC-1621', '@regression']},
38+
async ({pageManager}) => {
39+
const newUser = getUser();
40+
const unregisteredEmail = newUser.email;
41+
42+
await pageManager.openMainPage();
43+
const {pages} = pageManager.webapp;
44+
45+
await goToPersonalRegistration(pageManager, unregisteredEmail);
46+
47+
await expect(pages.registration().termsLabel).toBeVisible();
48+
49+
const pagePromise = pageManager.page.context().waitForEvent('page');
50+
51+
await pages.registration().termsLabel.click();
52+
53+
const newTab = await pagePromise;
54+
await newTab.waitForLoadState();
55+
await expect(newTab).toHaveURL(/legal#terms/);
56+
},
57+
);
58+
3559
test(
3660
'I want to be notified if the email address I entered during registration has already been registered',
3761
{tag: ['@TC-1623', '@TC-1640', '@regression']},

0 commit comments

Comments
 (0)