Skip to content

Commit

Permalink
Use jp-button instead of button
Browse files Browse the repository at this point in the history
  • Loading branch information
krassowski committed Apr 1, 2024
1 parent af9a5be commit dddc370
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ui-tests/tests/user-menu.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ test.use( {
});

const openDialog = async (page: IJupyterLabPageFixture): Promise<Locator> => {
const sharedLinkButton = page.locator('button[data-command="collaboration:shared-link"]');
const sharedLinkButton = page.locator('jp-button[data-command="collaboration:shared-link"]');
await sharedLinkButton.click();
await expect(page.locator('.jp-Dialog')).toBeVisible();
return page.locator('.jp-Dialog').first();
Expand All @@ -23,7 +23,7 @@ test('the top bar should contain the user menu with 2 items', async ({ page }) =
});

test('should open dialog when clicking on the shared link button', async ({ page }) => {
const sharedLinkButton = page.locator('button[data-command="collaboration:shared-link"]');
const sharedLinkButton = page.locator('jp-button[data-command="collaboration:shared-link"]');

expect(await sharedLinkButton.screenshot()).toMatchSnapshot(

Check failure on line 28 in ui-tests/tests/user-menu.spec.ts

View workflow job for this annotation

GitHub Actions / ui_tests

tests/user-menu.spec.ts:25:5 › should open dialog when clicking on the shared link button

7) tests/user-menu.spec.ts:25:5 › should open dialog when clicking on the shared link button ───── Error: Screenshot comparison failed: Expected an image 28px by 24px, received 21px by 21px. 50 pixels (ratio 0.08 of all image pixels) are different. Expected: /home/runner/work/jupyter_collaboration/jupyter_collaboration/ui-tests/test-results/tests-user-menu-should-open-dialog-when-clicking-on-the-shared-link-button/shared-link-icon-expected.png Received: /home/runner/work/jupyter_collaboration/jupyter_collaboration/ui-tests/test-results/tests-user-menu-should-open-dialog-when-clicking-on-the-shared-link-button/shared-link-icon-actual.png Diff: /home/runner/work/jupyter_collaboration/jupyter_collaboration/ui-tests/test-results/tests-user-menu-should-open-dialog-when-clicking-on-the-shared-link-button/shared-link-icon-diff.png 26 | const sharedLinkButton = page.locator('jp-button[data-command="collaboration:shared-link"]'); 27 | > 28 | expect(await sharedLinkButton.screenshot()).toMatchSnapshot( | ^ 29 | 'shared-link-icon.png' 30 | ); 31 | at /home/runner/work/jupyter_collaboration/jupyter_collaboration/ui-tests/tests/user-menu.spec.ts:28:47
'shared-link-icon.png'
Expand Down

0 comments on commit dddc370

Please sign in to comment.