Add release test for auto updater config

Without this file, clients would be stranded on the current version forever.
This change extends release-test to verify its presence in a packaged build.

// FREEBIE
This commit is contained in:
lilia 2017-05-23 15:16:57 -07:00 committed by Scott Nonnenberg
parent 00aabfd4e0
commit 349b6ce245
No known key found for this signature in database
GPG key ID: A4931C09644C654B

View file

@ -222,10 +222,12 @@ module.exports = function(grunt) {
'test-release': {
osx: {
archive: 'mac/Signal.app/Contents/Resources/app.asar',
appUpdateYML: 'mac/Signal.app/Contents/Resources/app-update.yml',
exe: 'mac/Signal.app/Contents/MacOS/Signal'
},
mas: {
archive: 'mas/Signal.app/Contents/Resources/app.asar',
appUpdateYML: 'mac/Signal.app/Contents/Resources/app-update.yml',
exe: 'mas/Signal.app/Contents/MacOS/Signal'
},
linux: {
@ -234,6 +236,7 @@ module.exports = function(grunt) {
},
win: {
archive: 'win-unpacked/resources/app.asar',
appUpdateYML: 'win-unpacked/resources/app-update.yml',
exe: 'win-unpacked/Signal.exe'
}
},
@ -437,6 +440,15 @@ module.exports = function(grunt) {
}
});
if (config.appUpdateYML) {
var appUpdateYML = [dir, config.appUpdateYML].join('/');
if (require('fs').existsSync(appUpdateYML)) {
console.log("auto update ok");
} else {
throw new Error("Missing auto update config " + appUpdateYML);
}
}
var done = this.async();
// A simple test to verify a visible window is opened with a title
var Application = require('spectron').Application;