Skip to content

Commit

Permalink
test: try to spit out more details on failures to grab snapshot images
Browse files Browse the repository at this point in the history
  • Loading branch information
sgtcoolguy committed Feb 3, 2021
1 parent 41c107a commit db10420
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion build/lib/test/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,19 @@ async function test(platforms, target, deviceId, deployType, deviceFamily, snaps

// If we're gathering images, make sure we get them all before we move on
if (snapshotPromises.length !== 0) {
await Promise.all(snapshotPromises);
try {
await Promise.all(snapshotPromises);
} catch (err) {
// If grabbing an image fails, can we report more details about why?
// The rejected error should have stdout/stderr properties
if (err.stderr) {
console.error(err.stderr);
}
if (err.stdout) {
console.log(err.stdout);
}
throw err;
}
}

return results;
Expand Down

0 comments on commit db10420

Please sign in to comment.