Skip to content
This repository was archived by the owner on Feb 23, 2023. It is now read-only.

spring-aot-test: Include test with multiple Extend or Nested #1474

Closed

Conversation

GregoireW
Copy link
Contributor

This tend to fix #1427

Sometime, test can have multiple @ExtendWith, for instance if you use TestContainer or simply use @ExtendWith(OutputCaptureExtension.class). The current version crash because such test are not picked up correctly.

Also, if you have @Nested test, those nested test are not picked up correctly and again, it result in a test failure.

This PR tend to fix that : Checking every value of @ExtendWith annotation and adding nested class if the enclosing class is a Spring test class.

Signed-off-by: GregoireW 24318548+GregoireW@users.noreply.github.com

Signed-off-by: GregoireW <24318548+GregoireW@users.noreply.github.com>
@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged or decided on label Jan 28, 2022
Signed-off-by: GregoireW <24318548+GregoireW@users.noreply.github.com>
@sdeleuze sdeleuze requested a review from bclozel January 31, 2022 11:18
@sdeleuze sdeleuze added this to the 0.11.3 milestone Jan 31, 2022
@sdeleuze sdeleuze added type: compatibility Native image compatibility issue and removed status: waiting-for-triage An issue we've not yet triaged or decided on labels Jan 31, 2022
@sdeleuze
Copy link
Contributor

sdeleuze commented Feb 8, 2022

@bclozel Can I merge this PR from you POV?

@bclozel bclozel closed this in 512ae39 Feb 9, 2022
@bclozel
Copy link
Contributor

bclozel commented Feb 9, 2022

I've just merged this PR, reducing its scope to repeated @ExtendWith annotations. I don't think we should go for nested tests support right now, especially in a maintenance release.

@GregoireW
Copy link
Contributor Author

Arrrrgggg...

Why not nested tests ?

right now

Do you plan to add this later?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
type: compatibility Native image compatibility issue
Development

Successfully merging this pull request may close these issues.

IT & Testcontainers - No auto configuration classes found in META-INF/spring.factories
4 participants