     it "displays the diff stat for modified files", ->
       fs.writeSync(filePath, "i've changed for the worse")
       project.getRepo().getPathStatus(filePath)
-      rootView.open(filePath)
+      rootView.openSync(filePath)
       expect(statusBar.gitStatusIcon).toHaveText('+1')
 
     it "displays the diff stat for new files", ->
-      rootView.open(newPath)
+      rootView.openSync(newPath)
       expect(statusBar.gitStatusIcon).toHaveText('+1')
 
     it "does not display for files not in the current project", ->
-      rootView.open('/tmp/atom-specs/not-in-project.txt')
+      rootView.openSync('/tmp/atom-specs/not-in-project.txt')
       expect(statusBar.gitStatusIcon).toBeHidden()
 
   describe "grammar label", ->

    it "displays the modified icon for a changed file", ->
      fs.writeSync(filePath, "i've changed for the worse")
      project.getRepo().getPathStatus(filePath)
      rootView.open(filePath)
      expect(statusBar.gitStatusIcon).toHaveClass('icon-diff-modified')

    it "doesn't display the modified icon for an unchanged file", ->
      rootView.open(filePath)
      expect(statusBar.gitStatusIcon).toHaveText('')

    it "displays the new icon for a new file", ->
      rootView.open(newPath)
      expect(statusBar.gitStatusIcon).toHaveClass('icon-diff-added')

    it "displays the ignored icon for an ignored file", ->
      rootView.open(ignoredPath)
      expect(statusBar.gitStatusIcon).toHaveClass('icon-diff-ignored')

    it "updates when a status-changed event occurs", ->
      fs.writeSync(filePath, "i've changed for the worse")
      project.getRepo().getPathStatus(filePath)
      rootView.open(filePath)
      expect(statusBar.gitStatusIcon).toHaveClass('icon-diff-modified')
      fs.writeSync(filePath, originalPathText)
      project.getRepo().getPathStatus(filePath)

    it "doesn't update the buffer modified indicator for the old buffer", ->
      oldBuffer = editor.getBuffer()
      expect(statusBar.bufferModified.text()).toBe ''
      rootView.openSync('sample.txt')
      oldBuffer.setText("new text")
      advanceClock(buffer.stoppedChangingDelay)
      expect(statusBar.bufferModified.text()).toBe ''
