vscode-powershell icon indicating copy to clipboard operation
vscode-powershell copied to clipboard

Un-register extension between steps to prevent cascading test failures

Open tsmarvin opened this issue 8 months ago • 2 comments

PR Summary

  • Add getRegisteredExtensions method to extension client to allow listing all registered extensions.
  • Update ensureEditorServicesIsConnected test method to un-register the extension if its already registered to prevent cascading test failures.

PR Checklist

Note: Tick the boxes below that apply to this pull request by putting an x between the square brackets. Please mark anything not applicable to this PR NA.

  • [x] PR has a meaningful title
  • [x] Summarized changes
  • [ ] PR has tests
  • [x] This PR is ready to merge and is not work in progress
    • If the PR is work in progress, please add the prefix WIP: to the beginning of the title and remove the prefix when the PR is ready

tsmarvin avatar Jun 29 '25 12:06 tsmarvin

@tsmarvin is there a particular issue this is fixing in the external API you are seeing?

JustinGrote avatar Jul 01 '25 15:07 JustinGrote

Sort of. I added this so that it was easier for me to debug the actual root cause issue I was having.

I added it pretty early on in my testing so I'm not 100% confident on why I was seeing the cascading registration errors, but i suspect the PSES internal host not starting left the test waiting for the connection and it skipped over the de-registration on timeout.

If you don't think it's necessary I won't be offended, just figured id submit the PR as it helped me personally when debugging. It seemed like it was the expected state for the start of several tests related to the method I added it to.

tsmarvin avatar Jul 01 '25 23:07 tsmarvin