     describe "when the item has a path", ->
       it "selects the entry with that path in the tree view if it is visible", ->
         sampleJs.click()
-        rootView.open(require.resolve('fixtures/tree-view/tree-view.txt'))
+        rootView.open(project.resolve('tree-view.txt'))
 
         expect(sampleTxt).toHaveClass 'selected'
         expect(treeView.find('.selected').length).toBe 1

    [ignoreFile] = []

    beforeEach ->
      ignoreFile = path.join(fs.resolveOnLoadPath('fixtures/tree-view'), '.gitignore')
      fs.writeSync(ignoreFile, 'tree-view.js')
      config.set "core.hideGitIgnoredFiles", false



      sampleJs.trigger clickEvent(originalEvent: { detail: 1 })
      expect(sampleJs).toHaveClass 'selected'
      expect(rootView.getActiveView().getPath()).toBe project.resolve('tree-view.js')
      expect(rootView.getActiveView().isFocused).toBeFalsy()

      sampleTxt.trigger clickEvent(originalEvent: { detail: 1 })
      expect(sampleTxt).toHaveClass 'selected'
      expect(treeView.find('.selected').length).toBe 1
      expect(rootView.getActiveView().getPath()).toBe project.resolve('tree-view.txt')
      expect(rootView.getActiveView().isFocused).toBeFalsy()

  describe "when a file is double-clicked", ->
    it "selects the file and opens it in the active editor on the first click, then changes focus to the active editor on the second", ->
      sampleJs.trigger clickEvent(originalEvent: { detail: 1 })
      expect(sampleJs).toHaveClass 'selected'
      expect(rootView.getActiveView().getPath()).toBe project.resolve('tree-view.js')
      expect(rootView.getActiveView().isFocused).toBeFalsy()

      sampleJs.trigger clickEvent(originalEvent: { detail: 2 })
