Skip to content

Refactor testing support #1702

Closed
Closed
@firelizzard18

Description

@firelizzard18

I mentioned this in #1641. I am opening a separate issue for discussing a specific change.

I would like to refactor goTest, testUtil, and goTestExplorer to all work together:

  • Rework goTest(tc: TestConfig) into runTests(rq: vscode.TestRunRequest, tc: TestConfig) and remove the properties of TestConfig that can easily be determined from the TestRunRequest.
  • Refactor {test,runTest,subTest}AtCursor and test{CurrentFile,CurrentPackage,Workspace} to work in terms of the test API/controller. For example, testAtCursor would become "Find the TestItem corresponding to the cursor location" and runTests(new vscode.TestRunRequest([testItemAtCursor]), testConfig).

Metadata

Metadata

Assignees

Labels

Go CompanionIssues relating to the Go Companion extensiongo-testissues related to go test support (test output, test explorer, ...)

Type

No type

Projects

Status

Done

Relationships

None yet

Development

No branches or pull requests

Issue actions