From 92615f964444a7f304bfee41cb13627b0457f85d Mon Sep 17 00:00:00 2001 From: Ruben de Vries Date: Wed, 23 Nov 2016 12:46:55 +0100 Subject: [PATCH] add check for test that errors before even starting a job --- src/Job.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Job.js b/src/Job.js index 2f395ec..9cbc80c 100644 --- a/src/Job.js +++ b/src/Job.js @@ -148,6 +148,10 @@ module.exports = function (grunt) { var result = body['js tests'] && body['js tests'][0]; var jobId = result.job_id; + if (result.status === 'test error') { + throw new Error("test throws unknown error"); + } + if (!body.completed || !reJobId.test(jobId)) { var retries = attempts - 1; if (attempts === 0) {