Expect the deserialization promise to reject with inaccessible dirs

This commit is contained in:
Ash Wilson 2017-09-18 11:20:51 -04:00
parent 3d51ed9766
commit 928a3e2854
No known key found for this signature in database
GPG Key ID: 81B1DDB704F69D2A

View File

@ -25,11 +25,14 @@ describe "Project", ->
state = atom.project.serialize()
state.paths.push('/directory/that/does/not/exist')
err = null
waitsForPromise ->
deserializedProject.deserialize(state, atom.deserializers)
.catch (e) -> err = e
runs ->
expect(deserializedProject.getPaths()).toEqual(atom.project.getPaths())
expect(err.missingProjectPaths).toEqual ['/directory/that/does/not/exist']
it "does not include unretained buffers in the serialized state", ->
waitsForPromise ->