add ResetConsumerGroupOffsetTest based on #58 (#68) #223
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Kafka Tests | |
on: | |
push: | |
branches: [main] | |
pull_request: | |
branches: [main] | |
jobs: | |
check: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest] | |
distribution: ["adopt"] | |
java-version: [11] | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: "recursive" | |
- uses: actions/setup-java@v4 | |
with: | |
distribution: ${{ matrix.distribution }} | |
java-version: ${{ matrix.java-version }} | |
cache: "gradle" | |
- uses: gradle/actions/wrapper-validation@v3 | |
- name: check Java code format | |
run: | | |
# TODO: Upstream kafka code has a different format, ignore this check. | |
# ./gradlew spotlessJavaCheck | |
./gradlew spotlessGroovyGradleCheck | |
pre-tests: | |
runs-on: ubuntu-latest | |
outputs: | |
legacy_tests: ${{ steps.collect_tests.outputs.legacy_tests }} | |
tests: ${{ steps.collect_tests.outputs.tests }} | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: "recursive" | |
- id: collect_tests | |
uses: ./.github/actions/collect-tests | |
legacy-tests: | |
needs: pre-tests | |
runs-on: ${{ matrix.os }} | |
name: legacy-tests (${{ matrix.os }}-${{ matrix.tests.kafka_client_version }}-${{ matrix.tests.tests_arg }}) | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ubuntu-latest] | |
distribution: ["adopt"] | |
java-version: [11] | |
tests: ${{ fromJson(needs.pre-tests.outputs.legacy_tests) }} | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: "recursive" | |
- id: run_tests | |
uses: ./.github/actions/run-tests | |
with: | |
distribution: ${{ matrix.distribution }} | |
java-version: ${{ matrix.java-version }} | |
tests_arg: ${{ matrix.tests.tests_arg }} | |
kafka_client_version: ${{ matrix.tests.kafka_client_version }} | |
is_lagacy_tests: 'true' | |
tests: | |
needs: pre-tests | |
runs-on: ${{ matrix.os }} | |
name: tests (${{ matrix.os }}-${{ matrix.tests.kafka_client_version }}-${{ matrix.tests.tests_arg }}) | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ubuntu-latest] | |
distribution: ["adopt"] | |
java-version: [11] | |
tests: ${{ fromJson(needs.pre-tests.outputs.tests) }} | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: "recursive" | |
- id: run_tests | |
uses: ./.github/actions/run-tests | |
with: | |
distribution: ${{ matrix.distribution }} | |
java-version: ${{ matrix.java-version }} | |
tests_arg: ${{ matrix.tests.tests_arg }} | |
kafka_client_version: ${{ matrix.tests.kafka_client_version }} | |
is_lagacy_tests: 'false' |