Do not explicitly require modules from project directory #713
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation and Context
Before this change, the following would fail if
cordova-android
or one of its dependencies are not resolvable fromdir
:This happens for example if you want to setup a platform-centered App from scratch. In my case I wanted to create a project in a temp folder during
plugman
test setups incordova-lib
.The problem is, that during project creation
cordova-android
requires some of the modules that have been checked-out to the project directory instead of the ones relative to the running modules (looking at the actual changes will probably clarify what I'm trying to say here).Description
Instead of switching to the checked-out modules in the created platform-project, we simply use the identical modules relative to the active ones.
Testing
Ran the automated test suite. Ran tests in
cordova-lib
that usecordova-android
using this updated version.