Skip to content

fix: text does not remember current settings #5655

fix: text does not remember current settings

fix: text does not remember current settings #5655

Triggered via pull request September 10, 2024 02:08
Status Success
Total duration 4m 17s
Artifacts

test.yml

on: pull_request
Install Dependencies
48s
Install Dependencies
Matrix: E2E Test
Matrix: Unit Test
Build & Test
0s
Build & Test
Fit to window
Zoom out
Zoom in

Annotations

12 errors, 20 warnings, and 20 notices
slash-menu.spec.ts:373:3 › slash menu should show and hide correctly › should open and close menu when using left right arrow: tests/slash-menu.spec.ts#L396
1) slash-menu.spec.ts:373:3 › slash menu should show and hide correctly › should open and close menu when using left right arrow, Enter, Esc keys Error: Timed out 5000ms waiting for expect(locator).toHaveAttribute(expected) Locator: locator('.slash-menu[data-testid=sub-menu-0]').locator('icon-button').nth(4) Expected string: "true" Received string: "false" Call log: - expect.toHaveAttribute with timeout 5000ms - waiting for locator('.slash-menu[data-testid=sub-menu-0]').locator('icon-button').nth(4) - locator resolved to <icon-button width="100%" tabindex="0" height="44px" hover="false" role="button" text="Other Headings" data-test-disabled="false" data-testid="Other Headings" class="slash-menu-item other-headings">…</icon-button> - unexpected value "false" - locator resolved to <icon-button width="100%" tabindex="0" height="44px" hover="false" role="button" text="Other Headings" data-test-disabled="false" data-testid="Other Headings" class="slash-menu-item other-headings">…</icon-button> - unexpected value "false" - locator resolved to <icon-button width="100%" tabindex="0" height="44px" hover="false" role="button" text="Other Headings" data-test-disabled="false" data-testid="Other Headings" class="slash-menu-item other-headings">…</icon-button> - unexpected value "false" - locator resolved to <icon-button width="100%" tabindex="0" height="44px" hover="false" role="button" text="Other Headings" data-test-disabled="false" data-testid="Other Headings" class="slash-menu-item other-headings">…</icon-button> - unexpected value "false" - locator resolved to <icon-button width="100%" tabindex="0" height="44px" hover="false" role="button" text="Other Headings" data-test-disabled="false" data-testid="Other Headings" class="slash-menu-item other-headings">…</icon-button> - unexpected value "false" - locator resolved to <icon-button width="100%" tabindex="0" height="44px" hover="false" role="button" text="Other Headings" data-test-disabled="false" data-testid="Other Headings" class="slash-menu-item other-headings">…</icon-button> - unexpected value "false" - locator resolved to <icon-button width="100%" tabindex="0" height="44px" hover="false" role="button" text="Other Headings" data-test-disabled="false" data-testid="Other Headings" class="slash-menu-item other-headings">…</icon-button> - unexpected value "false" - locator resolved to <icon-button width="100%" tabindex="0" height="44px" hover="false" role="button" text="Other Headings" data-test-disabled="false" data-testid="Other Headings" class="slash-menu-item other-headings">…</icon-button> - unexpected value "false" - locator resolved to <icon-button width="100%" tabindex="0" height="44px" hover="false" role="button" text="Other Headings" data-test-disabled="false" data-testid="Other Headings" class="slash-menu-item other-headings">…</icon-button> - unexpected value "false" 394 | await type(page, '/'); 395 | await pressArrowDown(page, 4); > 396 | await expect(slashItems.nth(4)).toHaveAttribute('hover', 'true'); | ^ 397 | await expect(slashItems.nth(4).locator('.text')).toHaveText([ 398 | 'Other Headings', 399 | ]); at /home/runner/work/blocksuite/blocksuite/tests/slash-menu.spec.ts:396:37
clipboard/clipboard.spec.ts:325:1 › clipboard copy nested items: tests/clipboard/clipboard.spec.ts#L348
1) clipboard/clipboard.spec.ts:325:1 › clipboard copy nested items ─────────────────────────────── Error: Snapshot comparison failed: bc d 456 Expected: /home/runner/work/blocksuite/blocksuite/tests/snapshots/clipboard/clipboard.spec.ts/clipboard-copy-nested-items-clipboard.md Received: /home/runner/work/blocksuite/blocksuite/tests/test-results/clipboard-clipboard-clipboard-copy-nested-items/clipboard-copy-nested-items-clipboard-actual.md 346 | const html = await getClipboardHTML(page); 347 | const snapshot = await getClipboardSnapshot(page); > 348 | expect(text).toMatchSnapshot(`${testInfo.title}-clipboard.md`); | ^ 349 | expect(JSON.stringify(snapshot.snapshot.content, null, 2)).toMatchSnapshot( 350 | `${testInfo.title}-clipboard.json` 351 | ); at /home/runner/work/blocksuite/blocksuite/tests/clipboard/clipboard.spec.ts:348:16
clipboard/list.spec.ts:96:1 › copy a nested list by clicking button: tests/clipboard/list.spec.ts#L126
2) clipboard/list.spec.ts:96:1 › copy a nested list by clicking button, the clipboard data should be complete Error: Snapshot comparison failed: aaa bbb ccc Thi Expected: /home/runner/work/blocksuite/blocksuite/tests/snapshots/clipboard/list.spec.ts/copy-a-nested-list-by-clicking-button-the-clipboard-data-should-be-complete-clipboard.md Received: /home/runner/work/blocksuite/blocksuite/tests/test-results/clipboard-list-copy-a-nest-7e308-ard-data-should-be-complete/copy-a-nested-list-by-clic-7b67b-ld-be-complete-clipboard-actual.md 124 | const html = await getClipboardHTML(page); 125 | const snapshot = await getClipboardSnapshot(page); > 126 | expect(text).toMatchSnapshot(`${testInfo.title}-clipboard.md`); | ^ 127 | expect(JSON.stringify(snapshot.snapshot.content, null, 2)).toMatchSnapshot( 128 | `${testInfo.title}-clipboard.json` 129 | ); at /home/runner/work/blocksuite/blocksuite/tests/clipboard/list.spec.ts:126:16
edgeless/shortcut.spec.ts:119:1 › should not switch shapes in editing: tests/utils/actions/edgeless.ts#L357
1) edgeless/shortcut.spec.ts:119:1 › should not switch shapes in editing ───────────────────────── TimeoutError: locator.click: Timeout 5000ms exceeded. Call log: - waiting for locator('edgeless-tool-icon-button').filter({ hasText: 'Square' }) - locator resolved to <edgeless-tool-icon-button role="button">…</edgeless-tool-icon-button> - attempting click action - waiting for element to be visible, enabled and stable - element is not stable - retrying click action, attempt #1 - waiting for element to be visible, enabled and stable - element was detached from the DOM, retrying at utils/actions/edgeless.ts:357 355 | .locator('edgeless-tool-icon-button') 356 | .filter({ hasText: shape }); > 357 | await squareShapeButton.click(); | ^ 358 | break; 359 | } 360 | } at setEdgelessTool (/home/runner/work/blocksuite/blocksuite/tests/utils/actions/edgeless.ts:357:31) at /home/runner/work/blocksuite/blocksuite/tests/edgeless/shortcut.spec.ts:137:3
hotkey.spec.ts:363:1 › should cut work single line: tests/hotkey.spec.ts#L372
1) hotkey.spec.ts:363:1 › should cut work single line ──────────────────────────────────────────── Error: Snapshot comparison failed: { "type": "block", "id": "0", "flavour": "affine:page", "version": 2, "props": { "title": { "$blocksuite:internal:text$": true, "delta": [] } }, "children": [ { "type": "block", "id": "1", "flavour": "affine:note", "version": 1, "props": { "xywh": "[0,0,800,95]", "background": "--affine-note-background-white", "index": "a0", "hidden": false, "displayMode": "both", "edgeless": { "style": { "borderRadius": 8, "borderSize": 4, "borderStyle": "none", "shadowType": "--affine-note-shadow-box" } } }, "children": [ { "type": "block", "id": "2", "flavour": "affine:paragraph", "version": 1, "props": { "type": "text", "text": { "$blocksuite:internal:text$": true, "delta": [ { "insert": "hello" } ] } }, "children": [] } ] } ] } Expected: /home/runner/work/blocksuite/blocksuite/tests/snapshots/hotkey.spec.ts/should-cut-work-single-line-init.json Received: /home/runner/work/blocksuite/blocksuite/tests/test-results/hotkey-should-cut-work-single-line/should-cut-work-single-line-init-actual.json 370 | // cut 371 | await page.keyboard.press(`${SHORT_KEY}+x`); > 372 | expect(await getPageSnapshot(page, true)).toMatchSnapshot( | ^ 373 | `${testInfo.title}_init.json` 374 | ); 375 | await undoByKeyboard(page); at /home/runner/work/blocksuite/blocksuite/tests/hotkey.spec.ts:372:45
hotkey.spec.ts:714:3 › keyboard operation to move block up or down › with indent: tests/utils/asserts.ts#L205
2) hotkey.spec.ts:714:3 › keyboard operation to move block up or down › with indent ────────────── Error: expect(received).toEqual(expected) // deep equality - Expected - 1 + Received + 1 Array [ - "foo", "hello", "world", + "foo", ] at utils/asserts.ts:205 203 | }); 204 | }, currentEditorIndex); > 205 | expect(actualTexts).toEqual(texts); | ^ 206 | } 207 | 208 | export async function assertEdgelessCanvasText(page: Page, text: string) { at assertRichTexts (/home/runner/work/blocksuite/blocksuite/tests/utils/asserts.ts:205:23) at /home/runner/work/blocksuite/blocksuite/tests/hotkey.spec.ts:731:5
hotkey.spec.ts:714:3 › keyboard operation to move block up or down › with indent: tests/utils/asserts.ts#L205
2) hotkey.spec.ts:714:3 › keyboard operation to move block up or down › with indent ────────────── Retry #1 ─────────────────────────────────────────────────────────────────────────────────────── Error: expect(received).toEqual(expected) // deep equality - Expected - 1 + Received + 1 Array [ - "foo", "hello", "world", + "foo", ] at utils/asserts.ts:205 203 | }); 204 | }, currentEditorIndex); > 205 | expect(actualTexts).toEqual(texts); | ^ 206 | } 207 | 208 | export async function assertEdgelessCanvasText(page: Page, text: string) { at assertRichTexts (/home/runner/work/blocksuite/blocksuite/tests/utils/asserts.ts:205:23) at /home/runner/work/blocksuite/blocksuite/tests/hotkey.spec.ts:731:5
edgeless/note/note.spec.ts:246:1 › duplicate note should work correctly: tests/edgeless/note/note.spec.ts#L272
1) edgeless/note/note.spec.ts:246:1 › duplicate note should work correctly ─────────────────────── Error: expect(received).toBeCloseTo(expected) Expected: 446.51165771484375 Received: 552.5580902099609 Expected precision: 2 Expected difference: < 0.005 Received difference: 106.04643249511719 270 | const firstNoteBox = await firstNote.boundingBox(); 271 | const secondNoteBox = await secondNote.boundingBox(); > 272 | expect(firstNoteBox!.width).toBeCloseTo(secondNoteBox!.width); | ^ 273 | expect(firstNoteBox!.height).toBeCloseTo(secondNoteBox!.height); 274 | }); 275 | at /home/runner/work/blocksuite/blocksuite/tests/edgeless/note/note.spec.ts:272:31
format-bar.spec.ts:237:1 › should format quick bar be able to change background color: tests/format-bar.spec.ts#L274
1) format-bar.spec.ts:237:1 › should format quick bar be able to change background color ───────── Error: Timed out 5000ms waiting for expect(locator).toBeVisible() Locator: locator('.affine-format-bar-widget').getByTestId('unset') Expected: visible Received: hidden Call log: - expect.toBeVisible with timeout 5000ms - waiting for locator('.affine-format-bar-widget').getByTestId('unset') - locator resolved to <editor-menu-action role="button" data-testid="unset">…</editor-menu-action> - unexpected value "hidden" - locator resolved to <editor-menu-action role="button" data-testid="unset">…</editor-menu-action> - unexpected value "hidden" - locator resolved to <editor-menu-action role="button" data-testid="unset">…</editor-menu-action> - unexpected value "hidden" - locator resolved to <editor-menu-action role="button" data-testid="unset">…</editor-menu-action> - unexpected value "hidden" - locator resolved to <editor-menu-action role="button" data-testid="unset">…</editor-menu-action> - unexpected value "hidden" - locator resolved to <editor-menu-action role="button" data-testid="unset">…</editor-menu-action> - unexpected value "hidden" - locator resolved to <editor-menu-action role="button" data-testid="unset">…</editor-menu-action> - unexpected value "hidden" - locator resolved to <editor-menu-action role="button" data-testid="unset">…</editor-menu-action> - unexpected value "hidden" - locator resolved to <editor-menu-action role="button" data-testid="unset">…</editor-menu-action> - unexpected value "hidden" 272 | ); 273 | > 274 | await expect(highlight.defaultColorBtn).toBeVisible(); | ^ 275 | await highlight.defaultColorBtn.click(); 276 | 277 | expect(await getPageSnapshot(page, true)).toMatchSnapshot( at /home/runner/work/blocksuite/blocksuite/tests/format-bar.spec.ts:274:43
edgeless/connector/label.spec.ts:306:3 › connector label with straight shape › should exit the label editing state when pressing `Mod-Enter` or `Escape`: tests/utils/asserts.ts#L226
1) edgeless/connector/label.spec.ts:306:3 › connector label with straight shape › should exit the label editing state when pressing `Mod-Enter` or `Escape` Error: expect(received).toEqual(expected) // deep equality Expected: "b" Received: "a" at utils/asserts.ts:226 224 | return inlineEditor?.yText.toString(); 225 | }); > 226 | expect(actualTexts).toEqual(text); | ^ 227 | } 228 | 229 | export async function assertRichImage(page: Page, count: number) { at assertEdgelessCanvasText (/home/runner/work/blocksuite/blocksuite/tests/utils/asserts.ts:226:23) at /home/runner/work/blocksuite/blocksuite/tests/edgeless/connector/label.spec.ts:323:5
edgeless/edgeless-text.spec.ts:211:3 › edgeless text block › edgeless text should maintain selection when deleting across multiple lines: tests/utils/asserts.ts#L594
2) edgeless/edgeless-text.spec.ts:211:3 › edgeless text block › edgeless text should maintain selection when deleting across multiple lines Error: expect(received).toBe(expected) // Object.is equality Expected: "ab" Received: "b" at utils/asserts.ts:594 592 | { id } 593 | ); > 594 | expect(actual).toBe(str); | ^ 595 | } 596 | 597 | export async function assertBlockProps( at assertBlockTextContent (/home/runner/work/blocksuite/blocksuite/tests/utils/asserts.ts:594:18) at /home/runner/work/blocksuite/blocksuite/tests/edgeless/edgeless-text.spec.ts:232:5
edgeless/selection/selection.spec.ts:198:1 › should auto panning when selection rectangle reaches viewport edges: tests/edgeless/selection/selection.spec.ts#L361
1) edgeless/selection/selection.spec.ts:198:1 › should auto panning when selection rectangle reaches viewport edges Error: Timed out 5000ms waiting for expect(locator).toBeVisible() Locator: locator('.affine-edgeless-selected-rect') Expected: visible Received: <element(s) not found> Call log: - expect.toBeVisible with timeout 5000ms - waiting for locator('.affine-edgeless-selected-rect') 359 | selectedRect = page.locator(selectedRectClass); 360 | await page.waitForTimeout(300); > 361 | await expect(selectedRect).toBeVisible(); | ^ 362 | }); 363 | 364 | test('should also update dragging area when viewport changes', async ({ at /home/runner/work/blocksuite/blocksuite/tests/edgeless/selection/selection.spec.ts:361:30
E2E Test (20)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (3)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (2)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (19)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (17)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (4)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (16)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (18)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (12)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (15)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (1)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (14)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (6)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (10)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (5)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (9)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (13)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (7)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (8)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
E2E Test (11)
Codecov: Failed to properly upload report: The process '/home/runner/work/_actions/codecov/codecov-action/v4/dist/codecov' failed with exit code 1
🎭 Playwright Run Summary
1 flaky slash-menu.spec.ts:373:3 › slash menu should show and hide correctly › should open and close menu when using left right arrow, Enter, Esc keys 3 skipped 40 passed (44.4s)
🎭 Playwright Run Summary
4 skipped 41 passed (44.2s)
🎭 Playwright Run Summary
2 flaky clipboard/clipboard.spec.ts:325:1 › clipboard copy nested items ──────────────────────────────── clipboard/list.spec.ts:96:1 › copy a nested list by clicking button, the clipboard data should be complete 1 skipped 42 passed (47.8s)
🎭 Playwright Run Summary
44 passed (51.9s)
🎭 Playwright Run Summary
44 passed (49.8s)
🎭 Playwright Run Summary
45 passed (55.5s)
🎭 Playwright Run Summary
44 passed (50.5s)
🎭 Playwright Run Summary
44 passed (56.3s)
🎭 Playwright Run Summary
1 flaky edgeless/shortcut.spec.ts:119:1 › should not switch shapes in editing ────────────────────────── 2 skipped 41 passed (1.1m)
🎭 Playwright Run Summary
1 skipped 43 passed (53.9s)
🎭 Playwright Run Summary
45 passed (55.1s)
🎭 Playwright Run Summary
2 flaky hotkey.spec.ts:363:1 › should cut work single line ───────────────────────────────────────────── hotkey.spec.ts:714:3 › keyboard operation to move block up or down › with indent ─────────────── 1 skipped 41 passed (56.6s)
🎭 Playwright Run Summary
44 passed (1.3m)
🎭 Playwright Run Summary
1 flaky edgeless/note/note.spec.ts:246:1 › duplicate note should work correctly ──────────────────────── 43 passed (1.3m)
🎭 Playwright Run Summary
45 passed (1.1m)
🎭 Playwright Run Summary
10 skipped 34 passed (1.1m)
🎭 Playwright Run Summary
1 flaky format-bar.spec.ts:237:1 › should format quick bar be able to change background color ────────── 43 passed (1.1m)
🎭 Playwright Run Summary
2 flaky edgeless/connector/label.spec.ts:306:3 › connector label with straight shape › should exit the label editing state when pressing `Mod-Enter` or `Escape` edgeless/edgeless-text.spec.ts:211:3 › edgeless text block › edgeless text should maintain selection when deleting across multiple lines 42 passed (1.6m)
🎭 Playwright Run Summary
44 passed (1.7m)
🎭 Playwright Run Summary
1 flaky edgeless/selection/selection.spec.ts:198:1 › should auto panning when selection rectangle reaches viewport edges 1 skipped 42 passed (1.7m)