Skip to content

[#14105] improvement(test): Let BackendTestExtension use JUnit's built-in store cleanup - #14085

Open
nevzheng wants to merge 4 commits into
apache:mainfrom
nevzheng:claude/13900-tc-00c-backend-autoclose
Open

nevzheng wants to merge 4 commits into
apache:mainfrom
nevzheng:claude/13900-tc-00c-backend-autoclose

Conversation

@nevzheng

@nevzheng nevzheng commented Oct 21, 2026 •

Copy link
Copy Markdown
Collaborator

What changes were proposed in this pull request?

  • BackendTestExtension keeps its per-class backend in the JUnit extension store as an AutoCloseable value, so JUnit closes it; the hand-written after-all cleanup goes away.
  • Lanes and row reset are unchanged.

Why are the changes needed?

JUnit 6's store closes AutoCloseable values with the context that owns them. Keeping the backend there removes the hand-written after-all cleanup, and the extension closes resources the same way the container fixtures in the framework PRs do.

Fix: #14105

Does this PR introduce any user-facing change?

No. Test code only.

How was this patch tested?

At the top of S0 (this PR, which carries #14103, #14083 and #14084):

Stack: #14103 → #14083 → #14084 → #14085 → #14005 → #14006 → #14052 → #14076 → #14007 → #14008 → #14009 → #14010 → #14011 → #14012 → #14013 → #14079 → #14077 → #14078 → #14086 → #14087 → #14088 → #14089 → #14090 → #14091 → #14094

@nevzheng nevzheng self-assigned this Oct 21, 2026
This was referenced Oct 21, 2026
@nevzheng
nevzheng force-pushed the claude/13900-tc-00c-backend-autoclose branch 7 times, most recently from a7d55cf to 7ce74f5 Compare October 21, 2026 19:28
@nevzheng
nevzheng force-pushed the claude/13900-tc-00c-backend-autoclose branch 3 times, most recently from 2422b13 to 326398b Compare October 21, 2026 19:44
@nevzheng
nevzheng force-pushed the claude/13900-tc-00c-backend-autoclose branch 2 times, most recently from dadc90f to c4eb059 Compare October 21, 2026 21:16
@nevzheng
nevzheng force-pushed the claude/13900-tc-00c-backend-autoclose branch from c4eb059 to c2d1f8f Compare October 21, 2026 21:18
@nevzheng nevzheng changed the title [#14001] improvement(test): Let BackendTestExtension use JUnit's built-in store cleanup [#14105] improvement(test): Let BackendTestExtension use JUnit's built-in store cleanup Oct 21, 2026
@nevzheng
nevzheng force-pushed the claude/13900-tc-00c-backend-autoclose branch from c2d1f8f to c248c7c Compare October 21, 2026 21:37
@nevzheng
nevzheng requested review from jerryshao and roryqi October 21, 2026 22:18
@nevzheng
nevzheng force-pushed the claude/13900-tc-00c-backend-autoclose branch 4 times, most recently from b003887 to 03c1b1c Compare October 22, 2026 03:28
@nevzheng
nevzheng force-pushed the claude/13900-tc-00c-backend-autoclose branch from 03c1b1c to 34d493e Compare October 22, 2026 04:29
@nevzheng
nevzheng marked this pull request as ready for review October 22, 2026 12:16
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.

[Subtask] Upgrade the test toolchain: remove JUnit 4, JUnit 6, Testcontainers 2

1 participant