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

Fix unit tests when run from symlinked directory #1595

Merged
merged 2 commits into from
Sep 7, 2012
Merged

Conversation

gruehle
Copy link
Member

@gruehle gruehle commented Sep 7, 2012

With the recent changes to the dev environment setup, there is no guarantee that our root folder is named "brackets". This updates the unit test runner accordingly.

@@ -81,7 +81,7 @@ define(function (require, exports, module) {
}

// This returns path to test folder, so convert to src
bracketsPath = bracketsPath.replace("brackets/test", "brackets/src");
bracketsPath = bracketsPath.replace("/test", "/src");
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems like we should make this an anchored regexp (assuming /test should be at the end of the path). Otherwise if you were a user whose username started with "tester", for example, this might not work.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good call - fixed.

@ghost ghost assigned njx Sep 7, 2012
@njx
Copy link

njx commented Sep 7, 2012

Reviewing

@njx
Copy link

njx commented Sep 7, 2012

Looks good, merging.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants