Skip to content

[FLINK-39768][tests][JUnit5 migration] Module: flink-avro - AvroStreamingFileSinkITCase straggler#28263

Open
spuru9 wants to merge 1 commit into
apache:masterfrom
spuru9:feature/junit5-avro-straggler
Open

[FLINK-39768][tests][JUnit5 migration] Module: flink-avro - AvroStreamingFileSinkITCase straggler#28263
spuru9 wants to merge 1 commit into
apache:masterfrom
spuru9:feature/junit5-avro-straggler

Conversation

@spuru9
Copy link
Copy Markdown
Contributor

@spuru9 spuru9 commented May 27, 2026

What is the purpose of the change

Migrate the last remaining JUnit 4 test in flink-formats/flink-avro (AvroStreamingFileSinkITCase) to JUnit 5 (Jupiter). The rest of the module was migrated under FLINK-26232 (fix 1.15.0); this file was a leftover. This is the sole change required to remove JUnit 4 from the module.

JIRA: FLINK-39768 (sub-task of FLINK-25325)

Brief change log

  • org.junit.* imports → org.junit.jupiter.api.*.
  • @Rule public Timeout timeoutPerTest = Timeout.seconds(20) → class-level @Timeout(value = 20).
  • extends AbstractTestBaseJUnit4extends AbstractTestBase (the JUnit 5 sibling).
  • TEMPORARY_FOLDER.newFolder() (static @ClassRule field on the JUnit 4 base) → TempDirUtils.newFolder(temporaryFolder.toPath()) (instance @TempDir on the JUnit 5 base).
  • Drop public on the test class and test methods per the Flink JUnit 5 Migration Guide.

No production code is touched.

Verifying this change

./mvnw -pl flink-formats/flink-avro test -Dtest=AvroStreamingFileSinkITCase

Result: 3 tests run, 0 failures, 0 errors, 0 skipped, matching the pre-migration baseline.

Does this pull request potentially affect one of the following parts:

  • Dependencies (does it add or upgrade a dependency): (no)
  • The public API, i.e., is any changed class annotated with @Public(Evolving): (no)
  • The serializers: (no)
  • The runtime per-record code paths (performance sensitive): (no)
  • Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Kubernetes/Yarn, ZooKeeper: (no)
  • The S3 file system connector: (no)

Documentation

  • Does this pull request introduce a new feature? (no)
  • If yes, how is the feature documented? (not applicable)

Was generative AI tooling used to co-author this PR?
  • Yes — Claude Code

…mingFileSinkITCase straggler

Migrate the last remaining JUnit 4 test in flink-avro to JUnit 5:

- org.junit.* -> org.junit.jupiter.api.*
- @rule Timeout -> class-level @timeout(value = 20)
- extends AbstractTestBaseJUnit4 -> extends AbstractTestBase
- TEMPORARY_FOLDER.newFolder() -> TempDirUtils.newFolder(temporaryFolder.toPath())
- Drop public modifiers on test class/methods per the migration guide

The rest of flink-avro was migrated in FLINK-26232; this file was a leftover.
@flinkbot
Copy link
Copy Markdown
Collaborator

flinkbot commented May 27, 2026

CI report:

Bot commands The @flinkbot bot supports the following commands:
  • @flinkbot run azure re-run the last Azure build

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.

2 participants