浏览代码

add timeout

Tienson Qin 2 年之前
父节点
当前提交
1041ebfb65
共有 1 个文件被更改,包括 3 次插入2 次删除
  1. 3 2
      e2e-tests/editor.spec.ts

+ 3 - 2
e2e-tests/editor.spec.ts

@@ -599,7 +599,7 @@ test('should keep correct undo and redo seq after indenting or outdenting the bl
   // should redo "bar" input
   await expect(page.locator('textarea >> nth=0')).toHaveText("bar")
   await page.keyboard.press("Shift+Tab", { delay: 10 })
-
+  await page.waitForTimeout(100)
   await page.keyboard.press("Enter")
   await page.waitForTimeout(100)
   await expect(page.locator('textarea >> nth=0')).toHaveText("")
@@ -611,8 +611,9 @@ test('should keep correct undo and redo seq after indenting or outdenting the bl
   // should undo indention
   await expect(page.locator('textarea >> nth=0')).toHaveText("baz")
   await page.keyboard.press("Shift+Tab")
-
+  await page.waitForTimeout(100)
   await page.keyboard.press("Enter")
+  await page.waitForTimeout(100)
   await expect(page.locator('textarea >> nth=0')).toHaveText("")
   // #7615
   await page.keyboard.type("aaa")