mirror of
https://github.com/pulsar-edit/pulsar.git
synced 2024-11-11 04:48:44 +03:00
💄
This commit is contained in:
parent
f199c71fa8
commit
5ff7a286fc
@ -299,16 +299,12 @@ describe "WorkspaceView", ->
|
||||
describe "saving the active item", ->
|
||||
describe "saveActivePaneItem", ->
|
||||
describe "when there is an error", ->
|
||||
beforeEach ->
|
||||
|
||||
it "emits a warning notification when the file cannot be saved", ->
|
||||
spyOn(Pane::, 'saveActiveItem').andCallFake ->
|
||||
throw new Error("'/some/file' is a directory")
|
||||
|
||||
atom.notifications.onDidAddNotification addedSpy = jasmine.createSpy()
|
||||
|
||||
atom.workspace.saveActivePaneItem()
|
||||
|
||||
expect(addedSpy).toHaveBeenCalled()
|
||||
expect(addedSpy.mostRecentCall.args[0].getType()).toBe 'warning'
|
||||
|
||||
@ -317,7 +313,6 @@ describe "WorkspaceView", ->
|
||||
throw new Error("ENOTDIR, not a directory '/Some/dir/and-a-file.js'")
|
||||
|
||||
atom.notifications.onDidAddNotification addedSpy = jasmine.createSpy()
|
||||
|
||||
atom.workspace.saveActivePaneItem()
|
||||
expect(addedSpy).toHaveBeenCalled()
|
||||
expect(addedSpy.mostRecentCall.args[0].getType()).toBe 'warning'
|
||||
|
Loading…
Reference in New Issue
Block a user