Skip to content

feat: add rerun and debug actions for failed tests from last run #251679

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

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

notoriousmango
Copy link
Contributor

resolves #244870

@@ -845,6 +867,17 @@ class TreeActionsProvider {
() => this.commandService.executeCommand('testing.reRunLastRun', element.value.id),
));

const hasFailedTests = Array.from(element.value.tests).some((test: TestResultItem) => isFailedState(test.ownComputedState));
Copy link
Member

Choose a reason for hiding this comment

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

we have a helper for this:

Suggested change
const hasFailedTests = Array.from(element.value.tests).some((test: TestResultItem) => isFailedState(test.ownComputedState));
const hasFailedTests = Iterable.some(element.value.tests, test => isFailedState(test.ownComputedState));

@@ -815,13 +815,35 @@ class TreeActionsProvider {
undefined,
() => this.commandService.executeCommand(TestCommandId.ReRunLastRun, element.results.id),
));

const hasFailedTests = Array.from(element.results.tests).some((test: TestResultItem) => isFailedState(test.ownComputedState));
Copy link
Member

@connor4312 connor4312 Jun 17, 2025

Choose a reason for hiding this comment

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

we have a helper for this:

Suggested change
const hasFailedTests = Array.from(element.results.tests).some((test: TestResultItem) => isFailedState(test.ownComputedState));
const hasFailedTests = Iterable.some(element.results.tests, test => isFailedState(test.ownComputedState));

@connor4312
Copy link
Member

Thanks for the PR! Just one comment

@connor4312
Copy link
Member

Thanks for the PR!

@connor4312 connor4312 enabled auto-merge (squash) June 18, 2025 01:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Test Results panel - allow Rerun failed from last run
2 participants