mirror of
https://github.com/pulsar-edit/pulsar.git
synced 2024-09-20 07:28:08 +03:00
Use a guard clause to disable integration specs
This commit is contained in:
parent
17894fd36b
commit
50010a55b9
@ -86,25 +86,23 @@ module.exports = (grunt) ->
|
||||
resourcePath = process.cwd()
|
||||
coreSpecsPath = path.resolve('spec')
|
||||
|
||||
# Integration tests require a fast machine and, for now, we cannot afford to
|
||||
# run them on Travis.
|
||||
env = _.extend({}, process.env,
|
||||
ATOM_INTEGRATION_TESTS_ENABLED: not process.env.TRAVIS
|
||||
)
|
||||
|
||||
if process.platform in ['darwin', 'linux']
|
||||
options =
|
||||
cmd: appPath
|
||||
args: ['--test', "--resource-path=#{resourcePath}", "--spec-directory=#{coreSpecsPath}"]
|
||||
opts:
|
||||
env: env
|
||||
env: _.extend({}, process.env,
|
||||
ATOM_INTEGRATION_TESTS_ENABLED: true
|
||||
)
|
||||
|
||||
else if process.platform is 'win32'
|
||||
options =
|
||||
cmd: process.env.comspec
|
||||
args: ['/c', appPath, '--test', "--resource-path=#{resourcePath}", "--spec-directory=#{coreSpecsPath}", "--log-file=ci.log"]
|
||||
opts:
|
||||
env: env
|
||||
env: _.extend({}, process.env,
|
||||
ATOM_INTEGRATION_TESTS_ENABLED: true
|
||||
)
|
||||
|
||||
grunt.log.ok "Launching core specs."
|
||||
spawn options, (error, results, code) ->
|
||||
|
@ -2,6 +2,9 @@
|
||||
#
|
||||
# ATOM_INTEGRATION_TESTS_ENABLED=true apm test
|
||||
return unless process.env.ATOM_INTEGRATION_TESTS_ENABLED
|
||||
# Integration tests require a fast machine and, for now, we cannot afford to
|
||||
# run them on Travis.
|
||||
return if process.env.TRAVIS
|
||||
|
||||
fs = require "fs"
|
||||
path = require "path"
|
||||
|
Loading…
Reference in New Issue
Block a user