Skip to content

proposal: testing: Listing the topN most time-consuming test cases as the last output #54198

Description

@bo-er

Every so often our team members have to check all the test cases to find the most time-consuming ones. Those time-consuming ones are generally badly designed and should not be left there, since they slow down our team's ability to move faster.
I personally believe that go test should be smart enough to list the top 10 most time-consuming test cases so that we don't have to look through the whole output( which is too long to read).
It's a tiny change that can make a lot of people's life easier.

Activity

  1. added this to the Proposal milestone on Aug 2, 2022
  2. seankhliao commented on Aug 2, 2022

    @seankhliao
    Member

    Various testing summary proposals have been declined in the past, see #41878 and linked issues.
    Building something on top of go test -json output would seem to be more appropriate for this niche usecase (you only care when they take too long).

  3. moved this to Incoming in Proposalson Aug 10, 2022
  4. changed the title [-]proposal: testing: Listing the topN most time-consuming test cases as the last output[/-] [+]proposal: testing: Listing the topN most time-consuming test cases as the last output[/+] on Aug 10, 2022
  5. seankhliao commented on Apr 6, 2025

    @seankhliao
    Member

    I think we should decline this as out of scope.
    Existing tooling such as gotestsum can handle this: https://github.com/gotestyourself/gotestsum?tab=readme-ov-file#post-run-command

  6. locked and limited conversation to collaborators on Apr 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions