Fix unhandled promise in smoke test.

This commit is contained in:
Guo Xiang Tan 2017-12-21 10:32:14 +08:00
parent 7b0f3f4e34
commit 8f6e2b7186
1 changed files with 3 additions and 1 deletions

View File

@ -53,7 +53,9 @@ const path = require('path');
page.on('console', msg => console.log(`PAGE LOG: ${msg.text}`));
await page.goto(url);
await exec("go to site", () => {
return page.goto(url);
});
await exec("expect a log in button in the header", () => {
return page.waitForSelector("header .login-button", { visible: true });