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

suite: recover and fail on subtest #1455

Conversation

anuragprafulla
Copy link

Summary

Changes

Motivation

Related issues

@dolmen
Copy link
Collaborator

dolmen commented Aug 11, 2023

Please spare the time of the maintainers by filling the description properly. If contributing in English is an issue, please at least tell that.

Also:

  • please provide an example of failure running on go.dev/play. Here is a template: https://go.dev/play/p/fjdBPM9UkcV
  • in your branch add a testcase that will serve for regression testing

@dolmen dolmen added bug pkg-suite Change related to package testify/suite labels Aug 11, 2023
@dolmen dolmen changed the title Recover and fail on subtest suite: recover and fail on subtest Aug 11, 2023
@@ -108,6 +108,7 @@ func (suite *Suite) Run(name string, subtest func()) bool {
}()

return oldT.Run(name, func(t *testing.T) {
defer recoverAndFailOnPanic(t)
Copy link
Collaborator

Choose a reason for hiding this comment

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

This change needs a matching test case for future regression testing.

@xwjdsh
Copy link

xwjdsh commented Aug 24, 2023

@dolmen I submitted a PR long ago and was just reminded by a reply. I noticed this PR was duplicated with it, could you please take a look #1293?

@dolmen
Copy link
Collaborator

dolmen commented Oct 16, 2023

@xwjdsh There are changes in #1471 which are about to be merged and are also related to suite subtests. Could you add your review there and tell me if there will be something remaining to fix in #1455 and #1293?

@dolmen
Copy link
Collaborator

dolmen commented Oct 30, 2023

Closing because this change is included in #1471.

@dolmen dolmen closed this Oct 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug pkg-suite Change related to package testify/suite
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants