       atom.workspace.open('sample.js')
 
     runs ->
-      expect(atom.workspaceView.getActivePaneItem().getCursorBufferPosition()).toEqual [0,0]
+      expect(atom.workspace.getActiveEditor().getCursorBufferPosition()).toEqual [0,0]
       expect(atom.workspaceView.find('.symbols-view')).not.toExist()
       atom.workspaceView.getActiveView().trigger "symbols-view:toggle-file-symbols"
 

          atom.workspace.open("tagged.js")

        runs ->
          editor = atom.workspaceView.getActivePaneItem()
          editor.setCursorBufferPosition([8,14])
          spyOn(SymbolsView.prototype, "moveToPosition").andCallThrough()
          atom.workspaceView.getActiveView().trigger 'symbols-view:go-to-declaration'

        atom.workspace.open("tagged.js")

      runs ->
        editor = atom.workspace.getActiveEditor()
        editor.setCursorBufferPosition([0,2])
        atom.workspaceView.getActiveView().trigger 'symbols-view:go-to-declaration'

