Skip to content

Commit

Permalink
Fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
brichet committed Jan 2, 2025
1 parent bffc973 commit f1ed2c2
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions ui-tests/tests/commands.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -111,14 +111,13 @@ test.describe('#menuNew', () => {
});

test.describe('#launcher', () => {
test('should have a launcher item in section', async ({ page }) => {
// Chat section
await expect(
page.locator('.jp-Launcher-sectionTitle:text("Chat")')
).toHaveCount(1);

// Chat tile
const tile = page.locator('.jp-LauncherCard[data-category="Chat"]');
test('should have a launcher chat tile in other section', async ({
page
}) => {
const tile = page
.locator('.jp-LauncherCard[data-category="Other"]')
.filter({ hasText: 'Chat' });
await expect(tile).toHaveCount(1);
expect(await tile.screenshot()).toMatchSnapshot('launcher-tile.png');

Check failure on line 121 in ui-tests/tests/commands.spec.ts

View workflow job for this annotation

GitHub Actions / Integration tests

tests/commands.spec.ts:114:7 › #launcher › should have a launcher chat tile in other section

1) tests/commands.spec.ts:114:7 › #launcher › should have a launcher chat tile in other section ── Error: Screenshot comparison failed: Expected an image 103px by 103px, received 103px by 114px. 182 pixels (ratio 0.02 of all image pixels) are different. Expected: /home/runner/work/jupyter-chat/jupyter-chat/ui-tests/tests/commands.spec.ts-snapshots/launcher-tile-linux.png Received: /home/runner/work/jupyter-chat/jupyter-chat/ui-tests/test-results/tests-commands--launcher-s-1dfa7--chat-tile-in-other-section/launcher-tile-actual.png Diff: /home/runner/work/jupyter-chat/jupyter-chat/ui-tests/test-results/tests-commands--launcher-s-1dfa7--chat-tile-in-other-section/launcher-tile-diff.png 119 | .filter({ hasText: 'Chat' }); 120 | await expect(tile).toHaveCount(1); > 121 | expect(await tile.screenshot()).toMatchSnapshot('launcher-tile.png'); | ^ 122 | }); 123 | 124 | test('should open modal create from the launcher', async ({ page }) => { at /home/runner/work/jupyter-chat/jupyter-chat/ui-tests/tests/commands.spec.ts:121:37

Check failure on line 121 in ui-tests/tests/commands.spec.ts

View workflow job for this annotation

GitHub Actions / Integration tests

tests/commands.spec.ts:114:7 › #launcher › should have a launcher chat tile in other section

1) tests/commands.spec.ts:114:7 › #launcher › should have a launcher chat tile in other section ── Retry #1 ─────────────────────────────────────────────────────────────────────────────────────── Error: Screenshot comparison failed: Expected an image 103px by 103px, received 103px by 114px. 182 pixels (ratio 0.02 of all image pixels) are different. Expected: /home/runner/work/jupyter-chat/jupyter-chat/ui-tests/tests/commands.spec.ts-snapshots/launcher-tile-linux.png Received: /home/runner/work/jupyter-chat/jupyter-chat/ui-tests/test-results/tests-commands--launcher-s-1dfa7--chat-tile-in-other-section-retry1/launcher-tile-actual.png Diff: /home/runner/work/jupyter-chat/jupyter-chat/ui-tests/test-results/tests-commands--launcher-s-1dfa7--chat-tile-in-other-section-retry1/launcher-tile-diff.png 119 | .filter({ hasText: 'Chat' }); 120 | await expect(tile).toHaveCount(1); > 121 | expect(await tile.screenshot()).toMatchSnapshot('launcher-tile.png'); | ^ 122 | }); 123 | 124 | test('should open modal create from the launcher', async ({ page }) => { at /home/runner/work/jupyter-chat/jupyter-chat/ui-tests/tests/commands.spec.ts:121:37

Check failure on line 121 in ui-tests/tests/commands.spec.ts

View workflow job for this annotation

GitHub Actions / Integration tests

tests/commands.spec.ts:114:7 › #launcher › should have a launcher chat tile in other section

1) tests/commands.spec.ts:114:7 › #launcher › should have a launcher chat tile in other section ── Retry #2 ─────────────────────────────────────────────────────────────────────────────────────── Error: Screenshot comparison failed: Expected an image 103px by 103px, received 103px by 114px. 182 pixels (ratio 0.02 of all image pixels) are different. Expected: /home/runner/work/jupyter-chat/jupyter-chat/ui-tests/tests/commands.spec.ts-snapshots/launcher-tile-linux.png Received: /home/runner/work/jupyter-chat/jupyter-chat/ui-tests/test-results/tests-commands--launcher-s-1dfa7--chat-tile-in-other-section-retry2/launcher-tile-actual.png Diff: /home/runner/work/jupyter-chat/jupyter-chat/ui-tests/test-results/tests-commands--launcher-s-1dfa7--chat-tile-in-other-section-retry2/launcher-tile-diff.png 119 | .filter({ hasText: 'Chat' }); 120 | await expect(tile).toHaveCount(1); > 121 | expect(await tile.screenshot()).toMatchSnapshot('launcher-tile.png'); | ^ 122 | }); 123 | 124 | test('should open modal create from the launcher', async ({ page }) => { at /home/runner/work/jupyter-chat/jupyter-chat/ui-tests/tests/commands.spec.ts:121:37
});

Expand Down

0 comments on commit f1ed2c2

Please sign in to comment.