diff --git a/spec/atom-spec.coffee b/spec/atom-spec.coffee index 52d7100b9..a61da1c85 100644 --- a/spec/atom-spec.coffee +++ b/spec/atom-spec.coffee @@ -175,8 +175,10 @@ describe "the `atom` global", -> expect(keymap.bindingsForElement(element3)['ctrl-y']).toBeUndefined() describe "menu loading", -> + beforeEach -> atom.contextMenu.definitions = [] + describe "when the metadata does not contain a 'menus' manifest", -> - it "loads all the .cson/.json files in the keymaps directory", -> + it "loads all the .cson/.json files in the menus directory", -> element = ($$ -> @div class: 'test-1')[0] expect(atom.contextMenu.definitionsForElement(element)).toEqual [] @@ -187,7 +189,7 @@ describe "the `atom` global", -> expect(atom.contextMenu.definitionsForElement(element)[1].label).toBe "Menu item 2" expect(atom.contextMenu.definitionsForElement(element)[2].label).toBe "Menu item 3" - describe "when the metadata contains a 'keymaps' manifest", -> + describe "when the metadata contains a 'menus' manifest", -> it "loads only the menus specified by the manifest, in the specified order", -> element = ($$ -> @div class: 'test-1')[0] diff --git a/spec/context-menu-manager-spec.coffee b/spec/context-menu-manager-spec.coffee index b819e7654..f21553027 100644 --- a/spec/context-menu-manager-spec.coffee +++ b/spec/context-menu-manager-spec.coffee @@ -67,8 +67,9 @@ describe "ContextMenuManager", -> expect(menu[0].label).toEqual 'parent' expect(menu[0].command).toEqual 'command-p' - expect(menu[1].label).toEqual 'dev-label' - expect(menu[1].command).toEqual 'dev-command' + expect(menu[1].type).toEqual 'separator' + expect(menu[2].label).toEqual 'dev-label' + expect(menu[2].command).toEqual 'dev-command' describe "on multiple elements", ->