Browse Source

Await sleeps.

Ian Rose 6 years ago
parent
commit
e96ecb38a0
1 changed files with 4 additions and 4 deletions
  1. 4 4
      tests/test-notebook/src/actions.spec.ts

+ 4 - 4
tests/test-notebook/src/actions.spec.ts

@@ -552,7 +552,7 @@ describe('@jupyterlab/notebook', () => {
         // Markdown rendering is asynchronous, but the cell
         // provides no way to hook into that. Sleep here
         // to make sure it finishes.
-        sleep(100);
+        await sleep(100);
         expect(result).to.equal(false);
         expect(child.rendered).to.equal(true);
         await ipySession.kernel.restart();
@@ -641,7 +641,7 @@ describe('@jupyterlab/notebook', () => {
         // Markdown rendering is asynchronous, but the cell
         // provides no way to hook into that. Sleep here
         // to make sure it finishes.
-        sleep(100);
+        await sleep(100);
         expect(result).to.equal(false);
         expect(cell.rendered).to.equal(true);
         expect(widget.activeCellIndex).to.equal(2);
@@ -719,7 +719,7 @@ describe('@jupyterlab/notebook', () => {
         // Markdown rendering is asynchronous, but the cell
         // provides no way to hook into that. Sleep here
         // to make sure it finishes.
-        sleep(100);
+        await sleep(100);
         expect(result).to.equal(false);
         expect(cell.rendered).to.equal(true);
         expect(widget.activeCellIndex).to.equal(2);
@@ -789,7 +789,7 @@ describe('@jupyterlab/notebook', () => {
         // Markdown rendering is asynchronous, but the cell
         // provides no way to hook into that. Sleep here
         // to make sure it finishes.
-        sleep(100);
+        await sleep(100);
         expect(result).to.equal(false);
         expect(cell.rendered).to.equal(true);
         await ipySession.kernel.restart();