Skip to content

Commit

Permalink
Add maven functional testing in github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
dnestoro committed Dec 24, 2024
1 parent e05d314 commit 9f33df0
Show file tree
Hide file tree
Showing 2 changed files with 93 additions and 59 deletions.
118 changes: 59 additions & 59 deletions .github/workflows/test-native-gradle-plugin.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,65 +43,6 @@ jobs:
id: set-matrix
run: ./gradlew -PmatrixType=gradle :native-gradle-plugin:dumpFunctionalTestList

test-native-gradle-plugin:
name: "Sanity checks"
runs-on: "ubuntu-20.04"
timeout-minutes: 50
strategy:
fail-fast: false
matrix:
java-version: [ 17 ]
os: [ ubuntu-20.04 ]
steps:
- name: "☁️ Checkout repository"
uses: actions/checkout@v4
- name: "🔧 Prepare environment"
uses: ./.github/actions/prepare-environment
with:
java-version: ${{ matrix.java-version }}
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: "❓ Unit tests and inspections"
run: ./gradlew :native-gradle-plugin:test :native-gradle-plugin:inspections
- name: "📜 Upload unit test results"
uses: actions/upload-artifact@v3
with:
name: unit-tests-results
path: native-gradle-plugin/build/reports/tests/test/

functional-testing-gradle-plugin-dev:
name: "Functional testing (GraalVM Dev Build)"
runs-on: ${{ matrix.os }}
env:
IS_GRAALVM_DEV_BUILD: 'true'
strategy:
fail-fast: false
matrix:
java-version: [ 17 ]
os: [ ubuntu-20.04 ]
steps:
- name: "☁️ Checkout repository"
uses: actions/checkout@v4
- name: "🔧 Prepare environment"
uses: ./.github/actions/prepare-environment
with:
java-version: ${{ matrix.java-version }}
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: "🔧 Install GraalVM (dev)"
uses: graalvm/setup-graalvm@main
with:
java-version: 'dev'
distribution: 'graalvm'
github-token: ${{ inputs.github-token }}
set-java-home: 'false'
- name: "❓ Check and test the plugin"
run: ./gradlew :native-gradle-plugin:functionalTest
- name: "📜 Upload functional tests results"
if: always()
uses: actions/upload-artifact@v3
with:
name: functional-tests-results-graalvm-dev
path: native-gradle-plugin/build/reports/tests/functionalTest/

functional-testing-gradle-plugin:
name: "🧪 Gradle: ${{ matrix.test }} on ${{ matrix.os }} with gradle version: ${{ matrix.gradle-version }}"
runs-on: ${{ matrix.os }}
Expand Down Expand Up @@ -171,3 +112,62 @@ jobs:
with:
name: functional-tests-results-${{ matrix.gradle-config-cache-version }}
path: native-gradle-plugin/build/reports/tests/functionalTest/

test-native-gradle-plugin:
name: "Sanity checks"
runs-on: "ubuntu-20.04"
timeout-minutes: 50
strategy:
fail-fast: false
matrix:
java-version: [ 17 ]
os: [ ubuntu-20.04 ]
steps:
- name: "☁️ Checkout repository"
uses: actions/checkout@v4
- name: "🔧 Prepare environment"
uses: ./.github/actions/prepare-environment
with:
java-version: ${{ matrix.java-version }}
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: "❓ Unit tests and inspections"
run: ./gradlew :native-gradle-plugin:test :native-gradle-plugin:inspections
- name: "📜 Upload unit test results"
uses: actions/upload-artifact@v3
with:
name: unit-tests-results
path: native-gradle-plugin/build/reports/tests/test/

functional-testing-gradle-plugin-dev:
name: "Functional testing (GraalVM Dev Build)"
runs-on: ${{ matrix.os }}
env:
IS_GRAALVM_DEV_BUILD: 'true'
strategy:
fail-fast: false
matrix:
java-version: [ 17 ]
os: [ ubuntu-20.04 ]
steps:
- name: "☁️ Checkout repository"
uses: actions/checkout@v4
- name: "🔧 Prepare environment"
uses: ./.github/actions/prepare-environment
with:
java-version: ${{ matrix.java-version }}
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: "🔧 Install GraalVM (dev)"
uses: graalvm/setup-graalvm@main
with:
java-version: 'dev'
distribution: 'graalvm'
github-token: ${{ inputs.github-token }}
set-java-home: 'false'
- name: "❓ Check and test the plugin"
run: ./gradlew :native-gradle-plugin:functionalTest
- name: "📜 Upload functional tests results"
if: always()
uses: actions/upload-artifact@v3
with:
name: functional-tests-results-graalvm-dev
path: native-gradle-plugin/build/reports/tests/functionalTest/
34 changes: 34 additions & 0 deletions .github/workflows/test-native-maven-plugin.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,3 +68,37 @@ jobs:
with:
name: maven-functional-tests-results-${{ matrix.os }}
path: native-maven-plugin/build/reports/tests/

functional-testing-maven-plugin-dev:
name: "Functional testing (GraalVM Dev Build)"
runs-on: ${{ matrix.os }}
env:
IS_GRAALVM_DEV_BUILD: 'true'
strategy:
fail-fast: false
matrix:
java-version: [ 17 ]
os: [ ubuntu-20.04 ]
steps:
- name: "☁️ Checkout repository"
uses: actions/checkout@v4
- name: "🔧 Prepare environment"
uses: ./.github/actions/prepare-environment
with:
java-version: ${{ matrix.java-version }}
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: "🔧 Install GraalVM (dev)"
uses: graalvm/setup-graalvm@main
with:
java-version: 'dev'
distribution: 'graalvm'
github-token: ${{ inputs.github-token }}
set-java-home: 'false'
- name: "❓ Check and test the plugin"
run: ./gradlew :native-maven-plugin:functionalTest
- name: "📜 Upload functional tests results"
if: always()
uses: actions/upload-artifact@v3
with:
name: functional-tests-results-graalvm-dev
path: native-maven-plugin/build/reports/tests/functionalTest/

0 comments on commit 9f33df0

Please sign in to comment.