Skip to content

Commit

Permalink
Merge pull request #5000 from camptocamp/checks
Browse files Browse the repository at this point in the history
Better errors behavior
  • Loading branch information
sbrunner authored Jul 10, 2019
2 parents 734c9c4 + e4f38f2 commit 0aec29c
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions buildtools/check-example.js
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,12 @@ function loaded(page, browser) {
process.exit(2);
}
});
await page.goto(url);
await page.goto(url).catch(error => {
console.log(`Page load error: ${error}.`);
process.exit(2);
});
loaded(page, browser);
})();
})().catch(error => {
console.log(`Unexpected error: ${error}.`);
process.exit(2);
});

0 comments on commit 0aec29c

Please sign in to comment.