Created
December 25, 2017 19:26
-
-
Save sashaegorov/dd195ba4c213c83fd65e4039bfc92f90 to your computer and use it in GitHub Desktop.
Revisions
-
sashaegorov created this gist
Dec 25, 2017 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,14 @@ function sleep (time, arg) { console.log(`Sleep started for ${arg}...`); return new Promise((resolve) => { setTimeout(() => { resolve(arg); }, time); }); } await sleep(1000, this.report.pagination.pageNumber) .then((a) => { console.log(`Sleep stopped ${a}...`); console.log(`Sleep stopped ${this}!`); });