           changeHandler.reset()
 
           fold.destroy()
-          expect(renderer.lineForRow(4).fold).toBeUndefined()
-          expect(renderer.lineForRow(4).text).toMatch /^4-+/
-          expect(renderer.lineForRow(4).bufferDelta).toEqual [1, 0]
-          expect(renderer.lineForRow(4).screenDelta).toEqual [1, 0]
-          expect(renderer.lineForRow(5).text).toBe '5'
+          [line4, line5] = renderer.linesForRows(4, 5)
+          expect(line4.fold).toBeUndefined()
+          expect(line4.text).toMatch /^4-+/
+          expect(line4.bufferDelta).toEqual [1, 0]
+          expect(line4.screenDelta).toEqual [1, 0]
+          expect(line5.text).toBe '5'
 
           expect(changeHandler).toHaveBeenCalled()
           [[event]] = changeHandler.argsForCall


          fold.destroy()

          expect(renderer.lineForRow(4).fold).toBeUndefined()
          expect(renderer.lineForRow(4).text).toMatch /^4-+/
          expect(renderer.lineForRow(4).bufferDelta).toEqual [1, 0]
          expect(renderer.lineForRow(4).screenDelta).toEqual [1, 0]
          expect(renderer.lineForRow(5).text).toBe '5'

          expect(changeHandler).toHaveBeenCalled()
          [[event]] = changeHandler.argsForCall

          expect(event.newRange).toEqual [[4, 0], [7, 1]]

      describe "when a fold spans a single line", ->
        it "renders a fold placeholder for the folded line but does not skip any lines", ->
          fold = renderer.createFold(4, 4)

          [line4, line5] = renderer.linesForRows(4, 5)
          expect(line4.fold).toBe fold
          expect(line4.text).toMatch /^4-+/
          expect(line4.bufferDelta).toEqual [1, 0]
          expect(line4.screenDelta).toEqual [1, 0]
          expect(line5.text).toBe '5'

          expect(changeHandler).toHaveBeenCalled()
          [[event]] = changeHandler.argsForCall
