         editor1 = atom.rootView.getActiveView()
         buffer = editor1.getBuffer()
         editor1.splitRight()
-        expect(rootView.getActiveView()).toBe atom.rootView.getEditors()[2]
+        expect(atom.rootView.getActiveView()).toBe atom.rootView.getEditors()[2]
 
         refreshRootViewAndProject()
 
-        expect(rootView.getEditors().length).toBe 2
-        expect(rootView.getActiveView()).toBe atom.rootView.getEditors()[1]
-        expect(rootView.title).toBe "untitled - #{project.getPath()}"
+        expect(atom.rootView.getEditors().length).toBe 2
+        expect(atom.rootView.getActiveView()).toBe atom.rootView.getEditors()[1]
+        expect(atom.rootView.title).toBe "untitled - #{atom.project.getPath()}"
 
     describe "when there are open editors", ->
       it "constructs the view with the same panes", ->

        pane2 = pane1.splitRight()
        pane3 = pane2.splitRight()
        pane4 = pane2.splitDown()
        pane2.showItem(project.openSync('b'))
        pane3.showItem(project.openSync('../sample.js'))
        pane3.activeItem.setCursorScreenPosition([2, 4])
        pane4.showItem(project.openSync('../sample.txt'))
        pane4.activeItem.setCursorScreenPosition([0, 2])
        pane2.focus()

        refreshRootViewAndProject()

        expect(rootView.getEditors().length).toBe 4
        editor1 = atom.rootView.panes.find('.row > .pane .editor:eq(0)').view()
        editor3 = atom.rootView.panes.find('.row > .pane .editor:eq(1)').view()
        editor2 = atom.rootView.panes.find('.row > .column > .pane .editor:eq(0)').view()

    refreshRootViewAndProject = ->
      project2 = atom.replicate().get('project')
      atom.project = project2
      rootViewState = atom.rootView.serialize()
      atom.project.getState().serializeForPersistence()
      atom.rootView.remove()
      atom.project.destroy()
