         describe "when the path without a trailing '/' is changed and confirmed", ->
           describe "when no file exists at that location", ->
             it "add a file, closes the dialog and selects the file in the tree-view", ->
-              newPath = fsUtils.join(dirPath, "new-test-file.txt")
+              newPath = path.join(dirPath, "new-test-file.txt")
               addDialog.miniEditor.insertText(path.basename(newPath))
               addDialog.trigger 'core:confirm'
               expect(fsUtils.exists(newPath)).toBeTruthy()

    [ignoreFile] = []

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



          describe "when the directories along the new path don't exist", ->
            it "creates the target directory before moving the file", ->
              newPath = path.join(rootDirPath, 'new/directory', 'renamed-test-file.txt')
              moveDialog.miniEditor.setText(newPath)

              moveDialog.trigger 'core:confirm'
