Skip to content

Conversation

v-zhocai
Copy link
Contributor

@v-zhocai v-zhocai commented Sep 15, 2025

Fix issues#8402

Changes:

  1. Use the new dependency package installation method to link the installation package in the local repository for emit, import, preview test, instead of the previous method of downloading from the remote repository.
  2. Switch emit test case from http-client-csharp to http-client-js.
  3. Add locator buffer in emit test to avoid slow pop-up of control panel in the stage of "Select an Emitter Type".
  4. Re enable typespec-vscode e2e test.

@microsoft-github-policy-service microsoft-github-policy-service bot added the ide Issues for VS, VSCode, Monaco, etc. label Sep 15, 2025
Copy link
Contributor

github-actions bot commented Sep 15, 2025

All changed packages have been documented.

  • typespec-vscode
Show changes

typespec-vscode - internal ✏️

Fix vscode e2e test when making a release pr

@v-zhocai v-zhocai force-pushed the fix_vscode_e2e_test branch from bfee85c to 283f091 Compare October 9, 2025 07:31
@v-zhocai v-zhocai force-pushed the fix_vscode_e2e_test branch from 283f091 to 76e3227 Compare October 9, 2025 07:35
Copy link
Member

Choose a reason for hiding this comment

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

revert this underlying issue was fixed

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We have re-verified and found that this issue has not been fixed. Could you please help double-check it?

Copy link
Member

@timotheeguerin timotheeguerin Oct 16, 2025

Choose a reason for hiding this comment

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

it is fixed in main but not published, which would work if we installed the local version as the other comment suggest

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sorry. We are now using local version packages in main and the reverted openapi.yaml file, but the import test is still failing. Did we miss something during our testing process? Could you please help take another look at this issue?

Copy link
Member

@timotheeguerin timotheeguerin Oct 17, 2025

Choose a reason for hiding this comment

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

yeah you are right, my bad, seems I only fixed the server description issue but not on server params.

Should be fixed here #8764

If you want to change the file I would also just go and make this teh most basic openapi3 file with nothing in it as the goal of this test is not really to test the converter but just the integration.

let shouldSkip = false;

shouldSkip = tryInstallAndHandle("@typespec/http") || shouldSkip;
shouldSkip = tryInstallAndHandle("@typespec/http-client-csharp") || shouldSkip;
Copy link
Member

Choose a reason for hiding this comment

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

could we maybe just use http-client-js as its already part of the workspace instead of csharp which is also extermly slow and require to keep inline with whatever other dependency they have

Copy link
Contributor Author

Choose a reason for hiding this comment

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

OK, we have now switched to using http-client-js for testing.

*/
export function tryInstallAndHandle(pkg: string): boolean {
try {
execSync(`pnpm install ${pkg}`, { stdio: "pipe" });
Copy link
Member

Choose a reason for hiding this comment

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

where is this being run? I think the source of most of this is that we should not also be patching anything on the vscode package.

Can this be done in a temp folder and link the lcoal version of every package(they are all there) to not depend on any extra remote issues

Copy link
Member

Choose a reason for hiding this comment

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

see the e2e-tests.js for the whole cli that does this with currrent

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The old method tryInstallAndHandle is being used before tests and has been removed. According to the e2e-test.js file you provided as a reference, we've implemented tests to use dependencies from the local repository instead of downloading them from a remote repository, and have also moved the tests to a temp folder beforehand.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ide Issues for VS, VSCode, Monaco, etc.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants