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

Test error doesn't appear when test item expanded #153993

Closed
r3m0t opened this issue Jul 2, 2022 · 2 comments · Fixed by #153994
Closed

Test error doesn't appear when test item expanded #153993

r3m0t opened this issue Jul 2, 2022 · 2 comments · Fixed by #153994
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug insiders-released Patch has been released in VS Code Insiders testing Built-in testing support verified Verification succeeded
Milestone

Comments

@r3m0t
Copy link
Contributor

r3m0t commented Jul 2, 2022

Does this issue occur when all extensions are disabled?: N/A

  • VS Code Version: 1.69.0-insider
  • OS Version: Windows 10

Steps to Reproduce:

  1. Build and install from VSIX the test-provider-sample from https://github.com/microsoft/vscode-extension-samples/compare/main...r3m0t:vscode-extension-samples:patch-1?expand=1 - this just sets TestItem.error instead of adding test cases.
  2. File> Open Folder.. and choose the Sample folder https://github.com/r3m0t/vscode-extension-samples/tree/patch-1/test-provider-sample/sample
  3. Open Testing panel and open test2.md
  4. Actual outcome: test2.md shows "expanded arrow" but error message doesn't appear. Error appears in Developer Tools

image

image

bootstrap-window.js:251 [uncaught exception]: TypeError: Cannot read properties of undefined (reading 'expand')
onUnexpectedError @ bootstrap-window.js:251
(anonymous) @ bootstrap-window.js:52
emit @ node:events:390
window.onerror @ node:electron/js2c/renderer_init:73
platform_1.globals.onerror @ errorTelemetry.ts:20
bootstrap-window.js:254 TypeError: Cannot read properties of undefined (reading 'expand')
at Object.getId (vscode-file://vscode-app/c:/Users/ther3/dev/vscode/out/vs/workbench/contrib/testing/browser/explorerProjections/nodeHelper.js:11:57)
at vscode-file://vscode-app/c:/Users/ther3/dev/vscode/out/vs/base/browser/ui/tree/indexTreeModel.js:140:92
at Array.map ()
at IndexTreeModel.spliceSimple (vscode-file://vscode-app/c:/Users/ther3/dev/vscode/out/vs/base/browser/ui/tree/indexTreeModel.js:140:62)
at IndexTreeModel.spliceSmart (vscode-file://vscode-app/c:/Users/ther3/dev/vscode/out/vs/base/browser/ui/tree/indexTreeModel.js:69:29)
at IndexTreeModel.splice (vscode-file://vscode-app/c:/Users/ther3/dev/vscode/out/vs/base/browser/ui/tree/indexTreeModel.js:60:22)
at ObjectTreeModel._setChildren (vscode-file://vscode-app/c:/Users/ther3/dev/vscode/out/vs/base/browser/ui/tree/objectTreeModel.js:66:24)
at ObjectTreeModel.setChildren (vscode-file://vscode-app/c:/Users/ther3/dev/vscode/out/vs/base/browser/ui/tree/objectTreeModel.js:31:18)
at WorkbenchObjectTree.setChildren (vscode-file://vscode-app/c:/Users/ther3/dev/vscode/out/vs/base/browser/ui/tree/objectTree.js:22:24)
at NodeChangeList.applyTo (vscode-file://vscode-app/c:/Users/ther3/dev/vscode/out/vs/workbench/contrib/testing/browser/explorerProjections/nodeHelper.js:83:26)
at HierarchicalByLocationProjection.applyTo (vscode-file://vscode-app/c:/Users/ther3/dev/vscode/out/vs/workbench/contrib/testing/browser/explorerProjections/hierarchalByLocation.js:190:26)
at TestingExplorerViewModel.applyProjectionChanges (vscode-file://vscode-app/c:/Users/ther3/dev/vscode/out/vs/workbench/contrib/testing/browser/testingExplorerView.js:590:36)
at RunOnceScheduler.runner (vscode-file://vscode-app/c:/Users/ther3/dev/vscode/out/vs/workbench/contrib/testing/browser/testingExplorerView.js:579:71)
at RunOnceScheduler.doRun (vscode-file://vscode-app/c:/Users/ther3/dev/vscode/out/vs/base/common/async.js:706:26)
at RunOnceScheduler.onTimeout (vscode-file://vscode-app/c:/Users/ther3/dev/vscode/out/vs/base/common/async.js:702:22)
onUnexpectedError @ bootstrap-window.js:254
(anonymous) @ bootstrap-window.js:52
emit @ node:events:390
window.onerror @ node:electron/js2c/renderer_init:73
platform_1.globals.onerror @ errorTelemetry.ts:20
nodeHelper.ts:13 Uncaught TypeError: Cannot read properties of undefined (reading 'expand')
at Object.getId (nodeHelper.ts:13:47)
at indexTreeModel.ts:275:79
at Array.map ()
at IndexTreeModel.spliceSimple (indexTreeModel.ts:275:49)
at IndexTreeModel.spliceSmart (indexTreeModel.ts:170:16)
at IndexTreeModel.splice (indexTreeModel.ts:154:9)
at ObjectTreeModel._setChildren (objectTreeModel.ts:122:14)
at ObjectTreeModel.setChildren (objectTreeModel.ts:71:8)
at WorkbenchObjectTree.setChildren (objectTree.ts:63:14)
at NodeChangeList.applyTo (nodeHelper.ts:101:10)
at HierarchicalByLocationProjection.applyTo (hierarchalByLocation.ts:195:16)
at TestingExplorerViewModel.applyProjectionChanges (testingExplorerView.ts:785:26)
at RunOnceScheduler.runner (testingExplorerView.ts:772:53)
at RunOnceScheduler.doRun (async.ts:886:16)
at RunOnceScheduler.onTimeout (async.ts:881:9)

@r3m0t
Copy link
Contributor Author

r3m0t commented Jul 2, 2022

I submitted a PR

@gjsjohnmurray
Copy link
Contributor

/assign @connor4312

@connor4312 connor4312 added bug Issue identified by VS Code Team member as probable bug testing Built-in testing support labels Jul 5, 2022
@connor4312 connor4312 added this to the July 2022 milestone Jul 5, 2022
@VSCodeTriageBot VSCodeTriageBot added unreleased Patch has not yet been released in VS Code Insiders insiders-released Patch has been released in VS Code Insiders and removed unreleased Patch has not yet been released in VS Code Insiders labels Jul 5, 2022
@aeschli aeschli added the verified Verification succeeded label Jul 27, 2022
@github-actions github-actions bot locked and limited conversation to collaborators Aug 19, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug insiders-released Patch has been released in VS Code Insiders testing Built-in testing support verified Verification succeeded
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants