 TagGenerator = require '../lib/tag-generator'
 
 describe "SymbolsView", ->
-  [symbolsView, setItemsSpy, setErrorSpy, activationPromise] = []
+  [symbolsView, activationPromise] = []
 
   beforeEach ->
     atom.workspaceView = new WorkspaceView
     atom.project.setPath(temp.mkdirSync('atom-symbols-view-'))
     fs.copySync(path.join(__dirname, 'fixtures'), atom.project.getPath())
-
     activationPromise = atom.packages.activatePackage("symbols-view")
-
     atom.workspaceView.attachToDom()
-    setItemsSpy = spyOn(SymbolsView.prototype, 'setItems').andCallThrough()
 
   describe "when tags can be generated for a file", ->
     it "initially displays all JavaScript functions with line numbers", ->

        expect(symbolsView.loading).toHaveText 'Generating symbols...'

      waitsFor ->
        setItemsSpy.callCount > 0

      runs ->
        expect(symbolsView.loading).toBeEmpty()


      runs ->
        symbolsView = atom.workspaceView.find('.symbols-view').view()

      waitsFor ->
        symbolsView.error.isVisible()

      runs ->
        expect(symbolsView).toExist()
