Skip to content
This repository was archived by the owner on Sep 6, 2021. It is now read-only.

Adding prefix to files that will be moved to trash in unit tests #5998

Merged
merged 1 commit into from
Nov 25, 2013
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions test/spec/LowLevelFileIO-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -542,7 +542,7 @@ define(function (require, exports, module) {
describe("makedir", function () {

it("should make a new directory", function () {
var newDirName = baseDir + "/new_dir",
var newDirName = baseDir + "/brackets_unittests_new_dir",
cb = errSpy(),
statCB = statSpy(),
trashCB = errSpy();
Expand Down Expand Up @@ -818,7 +818,7 @@ define(function (require, exports, module) {
var error, complete, isDirectory;

it("should move a file to the trash", function () {
var newFileName = baseDir + "/delete_me.txt",
var newFileName = baseDir + "/brackets_unittests_delete_me.txt",
writeFileCB = errSpy(),
trashCB = errSpy();

Expand Down Expand Up @@ -858,7 +858,7 @@ define(function (require, exports, module) {
});

it("should move a folder to the trash", function () {
var newDirName = baseDir + "/dir_to_delete",
var newDirName = baseDir + "/brackets_unittests_dir_to_delete",
makedirCB = errSpy(),
trashCB = errSpy();

Expand Down
12 changes: 6 additions & 6 deletions test/spec/ProjectManager-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ define(function (require, exports, module) {
describe("deleteItem", function () {
it("should delete the selected file in the project tree", function () {
var complete = false,
newFile = FileSystem.getFileForPath(testPath + "/delete_me.js"),
newFile = FileSystem.getFileForPath(testPath + "/brackets_unittests_delete_me.js"),
selectedFile,
error,
stat;
Expand All @@ -247,7 +247,7 @@ define(function (require, exports, module) {
// Create a file and select it in the project tree.
runs(function () {
complete = false;
ProjectManager.createNewItem(testPath, "delete_me.js", true)
ProjectManager.createNewItem(testPath, "brackets_unittests_delete_me.js", true)
.always(function () { complete = true; });
});
waitsFor(function () { return complete; }, "ProjectManager.createNewItem() timeout", 1000);
Expand All @@ -267,7 +267,7 @@ define(function (require, exports, module) {
expect(error).toBeFalsy();
expect(stat.isFile).toBe(true);
selectedFile = ProjectManager.getSelectedItem();
expect(selectedFile.fullPath).toBe(testPath + "/delete_me.js");
expect(selectedFile.fullPath).toBe(testPath + "/brackets_unittests_delete_me.js");
});

// Delete the selected file.
Expand Down Expand Up @@ -302,7 +302,7 @@ define(function (require, exports, module) {

it("should delete the selected folder and all items in it.", function () {
var complete = false,
newFolderName = testPath + "/toDelete/",
newFolderName = testPath + "/brackets_unittests_toDelete/",
rootFolderName = newFolderName,
rootFolderEntry,
error,
Expand All @@ -322,7 +322,7 @@ define(function (require, exports, module) {
// Create a folder
runs(function () {
complete = false;
ProjectManager.createNewItem(testPath, "toDelete", true, true)
ProjectManager.createNewItem(testPath, "brackets_unittests_toDelete", true, true)
.always(function () { complete = true; });
});
waitsFor(function () { return complete; }, "ProjectManager.createNewItem() timeout", 1000);
Expand All @@ -343,7 +343,7 @@ define(function (require, exports, module) {
expect(stat.isDirectory).toBe(true);

rootFolderEntry = ProjectManager.getSelectedItem();
expect(rootFolderEntry.fullPath).toBe(testPath + "/toDelete/");
expect(rootFolderEntry.fullPath).toBe(testPath + "/brackets_unittests_toDelete/");
});

// Create a sub folder
Expand Down