mirror of
https://github.com/atom/atom.git
synced 2026-01-24 22:38:20 -05:00
Use a temporary storage directory when running specs
This commit is contained in:
@@ -7,6 +7,7 @@ process.on 'uncaughtException', (error={}) ->
|
||||
{crashReporter, app} = require 'electron'
|
||||
fs = require 'fs-plus'
|
||||
path = require 'path'
|
||||
temp = require 'temp'
|
||||
yargs = require 'yargs'
|
||||
console.log = require 'nslog'
|
||||
|
||||
@@ -33,6 +34,8 @@ start = ->
|
||||
|
||||
if args.userDataDir?
|
||||
app.setPath('userData', args.userDataDir)
|
||||
else if args.test
|
||||
app.setPath('userData', temp.mkdirSync('atom-test-data'))
|
||||
|
||||
app.on 'ready', ->
|
||||
app.removeListener 'open-file', addPathToOpen
|
||||
|
||||
Reference in New Issue
Block a user