Skip to content

Commit

Permalink
🔥 broken test case from merge
Browse files Browse the repository at this point in the history
  • Loading branch information
smashwilson committed Apr 25, 2019
1 parent 5859544 commit f0a3b58
Showing 1 changed file with 0 additions and 37 deletions.
37 changes: 0 additions & 37 deletions spec/main-process/atom-application.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -727,43 +727,6 @@ describe('AtomApplication', function() {
assert.deepEqual(app.getAllWindows().map(w => Array.from(w._rootPaths)), [paths])
})
})

it('allows reopening an existing project after all windows are closed', async () => {
const tempDirPath = makeTempDir('reopen')

const atomApplication = buildAtomApplication()
sinon.stub(atomApplication, 'promptForPathToOpen')

// Open a window and then close it, leaving the app running
const [window] = await atomApplication.launch(parseCommandLine([]))
await focusWindow(window)
window.close()
await window.closedPromise

// Reopen one of the recent projects
atomApplication.emit('application:reopen-project', { paths: [tempDirPath] })

const windows = atomApplication.getAllWindows()

assert(windows.length === 1)

await focusWindow(windows[0])

await conditionPromise(
async () => (await getTreeViewRootDirectories(windows[0])).length === 1
)

// Check that the project was opened correctly.
assert.deepEqual(
await evalInWebContents(
windows[0].browserWindow.webContents,
send => {
send(atom.project.getPaths())
}
),
[tempDirPath]
)
})
}

describe('existing application re-use', function() {
Expand Down

0 comments on commit f0a3b58

Please sign in to comment.