Increase unit-tests timeout, improve error display, add set -e
FREEBIE
This commit is contained in:
parent
e1495e779c
commit
f43a5986da
2 changed files with 7 additions and 3 deletions
|
@ -369,7 +369,7 @@ module.exports = function(grunt) {
|
||||||
return app.client.execute(getMochaResults).then(function(data) {
|
return app.client.execute(getMochaResults).then(function(data) {
|
||||||
return Boolean(data.value);
|
return Boolean(data.value);
|
||||||
});
|
});
|
||||||
}, 5000, 'Expected to find window.mochaResults set!');
|
}, 10000, 'Expected to find window.mochaResults set!');
|
||||||
}).then(function() {
|
}).then(function() {
|
||||||
return app.client.execute(getMochaResults);
|
return app.client.execute(getMochaResults);
|
||||||
}).then(function(data) {
|
}).then(function(data) {
|
||||||
|
@ -384,7 +384,7 @@ module.exports = function(grunt) {
|
||||||
}
|
}
|
||||||
}).catch(function (error) {
|
}).catch(function (error) {
|
||||||
failure = function() {
|
failure = function() {
|
||||||
grunt.fail.fatal('Something went wrong: ' + error.stack);
|
grunt.fail.fatal('Something went wrong: ' + error.message + ' ' + error.stack);
|
||||||
};
|
};
|
||||||
}).then(function () {
|
}).then(function () {
|
||||||
// We need to use the failure variable and this early stop to clean up before
|
// We need to use the failure variable and this early stop to clean up before
|
||||||
|
@ -397,7 +397,7 @@ module.exports = function(grunt) {
|
||||||
}
|
}
|
||||||
done();
|
done();
|
||||||
}).catch(function (error) {
|
}).catch(function (error) {
|
||||||
console.error('Second-level error:', error.stack);
|
console.error('Second-level error:', error.message, error.stack);
|
||||||
if (failure) {
|
if (failure) {
|
||||||
failure();
|
failure();
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,9 +1,13 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then
|
if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then
|
||||||
export DISPLAY=:99.0
|
export DISPLAY=:99.0
|
||||||
sh -e /etc/init.d/xvfb start
|
sh -e /etc/init.d/xvfb start
|
||||||
sleep 3
|
sleep 3
|
||||||
fi
|
fi
|
||||||
|
|
||||||
grunt test
|
grunt test
|
||||||
|
|
||||||
grunt test-release:$TRAVIS_OS_NAME
|
grunt test-release:$TRAVIS_OS_NAME
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue