       beforeEach ->
         editor.setText(mediumSample)
         editor.setScrollTop(50)
+
         waitsFor -> minimapElement.frameRequested
         runs -> nextAnimationFrame()
 

      describe 'when the minimap cannot scroll', ->
        beforeEach ->
          editor.setText(smallSample)
          waitsFor -> minimapElement.frameRequested
          runs -> nextAnimationFrame()



    describe 'when the update is performed', ->
      beforeEach ->
        waitsFor -> nextAnimationFrame isnt noAnimationFrame
        runs ->
          nextAnimationFrame()
          visibleArea = minimapElement.shadowRoot.querySelector('.minimap-visible-area')

      it 'sets the visible area width and height', ->
        expect(visibleArea.offsetWidth).toEqual(minimapElement.clientWidth)
