Tests will run on wrong file if discovery is done with expanded files first
JustinGrote opened this issue · comments
Justin Grote commented
- Run extension with basic tests
- Set up the UI so that test explorer has all tests pre-expanded
- Reload and click the test tab so that all tests discover
- Run the last test, the test data will have the file URI of the wrong test
This is probably a carryover value during discovery
Justin Grote commented
The data comes back from the PesterInterface correct, so somewhere in testcontroller the data is getting mapped to the wrong testitem perhaps.
2023-06-28 08:42:38.026 [trace] Received discovery item from PesterInterface:
{"type":"Test","id":"C:\\USERS\\JGROTE\\PROJECTS\\VSCODE-ADAPTER\\SAMPLE\\TESTS\\TRUE.TESTS.PS1>>SIMPLETEST>>TRUE SHOULD BE TRUE","error":null,"file":"C:\\Users\\jgrote\\Projects\\vscode-adapter\\sample\\Tests\\True.Tests.ps1","startLine":1,"endLine":3,"label":"True should be true","result":"Failed","duration":0,"durationDetail":"(0ms|0ms)","message":null,"expected":null,"actual":null,"targetFile":null,"targetLine":-1,"parent":"C:\\USERS\\JGROTE\\PROJECTS\\VSCODE-ADAPTER\\SAMPLE\\TESTS\\TRUE.TESTS.PS1>>SIMPLETEST","tags":[]}