Fix specs on Windows when running without desktop session

This commit is contained in:
Cheng Zhao 2016-04-30 20:51:09 +09:00
parent 33370b18b3
commit f65f8918c9
2 changed files with 10 additions and 0 deletions

View file

@ -1,7 +1,13 @@
const assert = require('assert') const assert = require('assert')
const desktopCapturer = require('electron').desktopCapturer const desktopCapturer = require('electron').desktopCapturer
const isCI = require('electron').remote.getGlobal('isCi')
describe('desktopCapturer', function () { describe('desktopCapturer', function () {
if (isCI && process.platform === 'win32') {
return
}
it('should return a non-empty array of sources', function (done) { it('should return a non-empty array of sources', function (done) {
desktopCapturer.getSources({ desktopCapturer.getSources({
types: ['window', 'screen'] types: ['window', 'screen']

View file

@ -62,6 +62,10 @@ describe('chromium feature', function () {
w.loadURL(url) w.loadURL(url)
}) })
if (isCI && process.platform === 'win32') {
return
}
it('is set correctly when window is inactive', function (done) { it('is set correctly when window is inactive', function (done) {
w = new BrowserWindow({ w = new BrowserWindow({
show: false show: false