Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Web: allow to run extension tests #83145

Closed
bpasero opened this issue Oct 23, 2019 · 6 comments
Closed

Web: allow to run extension tests #83145

bpasero opened this issue Oct 23, 2019 · 6 comments
Assignees
Labels
debug Debug viewlet, configurations, breakpoints, adapter issues feature-request Request for new features or functionality verification-needed Verification of issue is requested verified Verification succeeded web Issues related to running VSCode in the web
Milestone

Comments

@bpasero
Copy link
Member

bpasero commented Oct 23, 2019

Currently seems to not set the extension tests path properly.

@bpasero bpasero added feature-request Request for new features or functionality debug Debug viewlet, configurations, breakpoints, adapter issues web Issues related to running VSCode in the web labels Oct 23, 2019
@bpasero bpasero added this to the October 2019 milestone Oct 23, 2019
@weinand
Copy link
Contributor

weinand commented Oct 24, 2019

There are two issues:

  • the environment attribute 'extensionTestsPath' needs to be passed properly.
  • when running VS Code in the web UI or in a remote setup, the value of the extensionTestsPath attribute must be a valid path that exists in the filesystem. This is a problem because for historical reasons the path generated by yeoman is ${workspaceFolder}/out/test/suite/index which does not exist in the filesystem (because it lacks the file extension .js). When running tests locally, the non-existing path is not an issue because mocha will find the tests anyway.

The first problem has been fixed in VS Code.

The second problem requires a change in "node-debug2": we have to cope with paths that lack a ".js" extension. I've created microsoft/vscode-node-debug2#245 to address this.

Without the second fix a workaround is needed in order to run extension tests in the Web or remote scenarios successfully: just append the ".js" extension to the ${workspaceFolder}/out/test/suite/index path.

weinand added a commit that referenced this issue Oct 24, 2019
weinand added a commit to microsoft/vscode-node-debug2 that referenced this issue Oct 24, 2019
Paths that lack a ".js" extension are not recognized as paths and are not properly processed in remote scenarios.
For details see microsoft/vscode#83145 (comment)
@bpasero bpasero added the verification-needed Verification of issue is requested label Oct 24, 2019
@bpasero
Copy link
Member Author

bpasero commented Oct 24, 2019

Verification: open a hello world extension in the web and run its unit tests.

@weinand
Copy link
Contributor

weinand commented Oct 25, 2019

One issue left: the tab where the VS Code instance runs the tests is not closed automatically at the end. See bug #83281.

@bpasero bpasero added the verified Verification succeeded label Oct 29, 2019
@roblourens
Copy link
Member

I hadn't published node2 with the fix. Doing that now, we can reverify this tomorrow.

@roblourens roblourens removed the verified Verification succeeded label Oct 31, 2019
@weinand
Copy link
Contributor

weinand commented Nov 1, 2019

Verification is trivial:

  • open a hello world extension in the web and run its unit tests.

@alexr00
Copy link
Member

alexr00 commented Nov 1, 2019

@alexr00 alexr00 added the verified Verification succeeded label Nov 1, 2019
@vscodebot vscodebot bot locked and limited conversation to collaborators Dec 8, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
debug Debug viewlet, configurations, breakpoints, adapter issues feature-request Request for new features or functionality verification-needed Verification of issue is requested verified Verification succeeded web Issues related to running VSCode in the web
Projects
None yet
Development

No branches or pull requests

4 participants