           editor = atom.workspace.getActiveTextEditor()
           originalText = editor.getText()
           originalPath = editor.getPath()
-          newPath = atom.project.resolve('newsample.js')
+          newPath = atom.project.getDirectories()[0].resolve('newsample.js')
           fs.writeFileSync(newPath, '')
 
       describe "when a modified file is shown in the list", ->

      runs ->
        [leftPane, rightPane] = atom.workspace.getPanes()
        expect(atom.workspace.getActivePane()).toBe rightPane
        expect(atom.workspace.getActiveTextEditor().getPath()).toBe atom.project.resolve(filePath)

    it "opens the path by splitting the active editor up", ->
      expect(atom.workspace.getPanes().length).toBe 1

        bufferView.filterEditorView.getModel().setText('sample.js:4')
        bufferView.populateList()
        {filePath} = bufferView.getSelectedItem()
        expect(atom.project.getDirectories()[0].resolve(filePath)).toBe editor1.getPath()

        spyOn(bufferView, 'moveToLine').andCallThrough()
        atom.commands.dispatch bufferView.element, 'core:confirm'
