diff --git a/spec/app/select-list-spec.coffee b/spec/app/select-list-spec.coffee index a39c4a128..5702fe546 100644 --- a/spec/app/select-list-spec.coffee +++ b/spec/app/select-list-spec.coffee @@ -124,6 +124,9 @@ describe "SelectList", -> expect(selectList.confirmed).toHaveBeenCalledWith(array[2]) describe "when there is no item selected (because the list is empty)", -> + beforeEach -> + selectList.attachToDom() + it "does not trigger the confirmed hook", -> miniEditor.insertText("i will never match anything") window.advanceClock(selectList.inputThrottle) diff --git a/src/packages/autocomplete/spec/autocomplete-spec.coffee b/src/packages/autocomplete/spec/autocomplete-spec.coffee index b525a8fe7..0bc25a3f0 100644 --- a/src/packages/autocomplete/spec/autocomplete-spec.coffee +++ b/src/packages/autocomplete/spec/autocomplete-spec.coffee @@ -288,6 +288,9 @@ describe "AutocompleteView", -> expect(editor.lineForBufferRow(10)).toBe matchToSelect.text() describe "when the mini-editor receives keyboard input", -> + beforeEach -> + editor.attachToDom() + describe "when text is removed from the mini-editor", -> it "reloads the match list based on the mini-editor's text", -> editor.getBuffer().insert([10,0] ,"t")