refactor: use sandbox.path instead of SANDBOX to access the sandbox directory#5014
Merged
raymondfeng merged 1 commit intomasterfrom Apr 3, 2020
Merged
refactor: use sandbox.path instead of SANDBOX to access the sandbox directory#5014raymondfeng merged 1 commit intomasterfrom
raymondfeng merged 1 commit intomasterfrom
Conversation
This was referenced Apr 2, 2020
bajtos
suggested changes
Apr 2, 2020
Member
bajtos
left a comment
There was a problem hiding this comment.
Cross-posting from #5016 (review):
I love the idea of changing the code to use sandbox.path. Considering that SANDBOX_PATH should not be used any more, I think our code would be much less error-prone if the constant was removed completely.
Now:
const SANDBOX_PATH = path.resolve(__dirname, '../.sandbox');
const sandbox = new TestSandbox(SANDBOX_PATH);My proposal:
const sandbox = new TestSandbox(path.resolve(__dirname, '../.sandbox'));324d86a to
9ea5243
Compare
Contributor
Author
|
@bajtos The SANDBOX constants are removed. |
6d9ff7a to
d67658a
Compare
bajtos
approved these changes
Apr 3, 2020
Member
bajtos
left a comment
There was a problem hiding this comment.
Thank you for removing SANDBOX constants 👏 The pull request is almost ready now 🏁
agnes512
approved these changes
Apr 3, 2020
emonddr
approved these changes
Apr 3, 2020
…irectory The starting path for a sandbox is not necessarily the target directory as we may create a unique subdir under the path to ensure sandboxes can be used in parallel testing.
d67658a to
7e2ade7
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Step 1 for #5011
Refactor test sandbox usage to use
sandbox.pathto access the sandbox directory as we'll create unique subdirs for different sandbox instances.Checklist
👉 Read and sign the CLA (Contributor License Agreement) 👈
npm testpasses on your machinepackages/cliwere updatedexamples/*were updated👉 Check out how to submit a PR 👈