Skip to content

Commit 9633011

Browse files
committed
test: adjust tests for chat heading changes
1 parent 8ac308c commit 9633011

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

packages/e2e-tests/tests/basic-tests.spec.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -403,16 +403,16 @@ test('correct handling of changed profile displaynames', async () => {
403403
.locator('.chat-list .chat-list-item')
404404
.filter({ hasText: newDisplayName })
405405
.click()
406-
const profileButton = page.getByTestId('chat-info-button')
407-
await expect(profileButton).toContainText(newDisplayName)
408-
await profileButton.click()
406+
const chatHeading = page.getByRole('heading', { name: 'Chat' })
407+
await expect(chatHeading).toContainText(newDisplayName)
408+
await page.getByTestId('chat-info-button').click()
409409
await page.locator('#view-profile-menu').click()
410410
await page.getByTestId('edit-contact-name').click()
411411
await page.getByTestId('edit-contact-name-input').fill(contactNameGivenByMe)
412412
await page.getByTestId('ok').click()
413413
await page.getByTestId('dialog-header-close').click()
414414
// profile shows the name I gave to the contact
415-
await expect(profileButton).toContainText(contactNameGivenByMe)
415+
await expect(chatHeading).toContainText(contactNameGivenByMe)
416416

417417
await switchToProfile(page, userA.id)
418418
await editProfileName('Alice Wonderland 2')

0 commit comments

Comments
 (0)