           editor.trigger 'delete-to-end-of-word'
           expect(buffer.lineForRow(1)).toBe '  var sort = function(it) {'
 
-    describe "when undo/redo events are triggered on the editor", ->
+    describe "undo/redo", ->
       it "undoes/redoes the last change", ->
         buffer.insert [0, 0], "foo"
         editor.trigger 'undo'

          expect(editor.lines.find('.line:eq(2)')).toHaveHtml '&nbsp;'
          expect(editor.getCursorScreenPosition()).toEqual(row: 2, column: 0)

    describe "when backspace is pressed", ->
      describe "when the cursor is on the middle of the line", ->
        it "removes the character before the cursor", ->
          editor.setCursorScreenPosition(row: 1, column: 7)

          expect(buffer.lineForRow(1)).toBe '  var qif (items.length <= 1) return items;'
          expect(editor.getCursorScreenPosition()).toEqual [1, 7]

    describe "return", ->
      describe "when the cursor is at the beginning of a line", ->
        it "inserts an empty line before it", ->
          editor.setCursorScreenPosition(row: 1, column: 0)
