Feature/fleet mode rebase #12
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: pre-review | |
on: | |
pull_request_target: | |
branches: | |
- main | |
- release-* | |
jobs: | |
repolint: | |
name: "Repository Linting" | |
runs-on: ubuntu-22.04 | |
container: ghcr.io/todogroup/repolinter:v0.11.2 | |
steps: | |
- name: Checkout Code | |
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 | |
with: | |
ref: ${{ github.event.pull_request.head.sha || github.ref }} | |
- name: Lint Repo | |
run: bundle exec /app/bin/repolinter.js --rulesetUrl https://raw.githubusercontent.com/hyperledger-labs/hyperledger-community-management-tools/main/repo_structure/repolint.json --format markdown | |
gradle-wrapper: | |
name: "Gradle Wrapper Validation" | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 | |
with: | |
ref: ${{ github.event.pull_request.head.sha || github.ref }} | |
- uses: gradle/wrapper-validation-action@56b90f209b02bf6d1deae490e9ef18b21a389cd4 | |
spotless: | |
runs-on: ubuntu-22.04 | |
if: ${{ github.actor != 'dependabot[bot]' }} | |
steps: | |
- name: Checkout Repo | |
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 | |
with: | |
ref: ${{ github.event.pull_request.head.sha || github.ref }} | |
- name: Set up Java | |
uses: actions/setup-java@387ac29b308b003ca37ba93a6cab5eb57c8f5f93 | |
with: | |
distribution: temurin | |
java-version: 17 | |
- name: Setup Gradle | |
uses: gradle/actions/setup-gradle@9e899d11ad247ec76be7a60bc1cf9d3abbb9e7f1 | |
- name: run spotless | |
run: ./gradlew spotlessCheck -Dorg.gradle.parallel=true -Dorg.gradle.caching=true | |
compile: | |
runs-on: ubuntu-22.04 | |
timeout-minutes: 30 | |
needs: [spotless, gradle-wrapper, repolint] | |
steps: | |
- name: Checkout Repo | |
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 | |
with: | |
ref: ${{ github.event.pull_request.head.sha || github.ref }} | |
- name: Set up Java | |
uses: actions/setup-java@387ac29b308b003ca37ba93a6cab5eb57c8f5f93 | |
with: | |
distribution: temurin | |
java-version: 17 | |
- name: Setup Gradle | |
uses: gradle/actions/setup-gradle@9e899d11ad247ec76be7a60bc1cf9d3abbb9e7f1 | |
- name: Gradle Compile | |
run: ./gradlew build -x test -x spotlessCheck -Dorg.gradle.parallel=true -Dorg.gradle.caching=true | |
unitTests: | |
env: | |
GRADLEW_UNIT_TEST_ARGS: ${{matrix.gradle_args}} | |
runs-on: ubuntu-22.04 | |
needs: [ compile ] | |
permissions: | |
checks: write | |
statuses: write | |
strategy: | |
fail-fast: true | |
matrix: | |
gradle_args: | |
- "test -x besu:test -x consensus:test -x crypto:test -x ethereum:eth:test -x ethereum:api:test -x ethereum:core:test" | |
- "besu:test consensus:test crypto:test" | |
- "ethereum:api:testBonsai" | |
- "ethereum:api:testForest" | |
- "ethereum:api:testRemainder" | |
- "ethereum:eth:test" | |
- "ethereum:core:test" | |
steps: | |
- name: Checkout Repo | |
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 | |
with: | |
ref: ${{ github.event.pull_request.head.sha || github.ref }} | |
- name: Set up Java | |
uses: actions/setup-java@387ac29b308b003ca37ba93a6cab5eb57c8f5f93 | |
with: | |
distribution: temurin | |
java-version: 17 | |
- name: Setup Gradle | |
uses: gradle/actions/setup-gradle@9e899d11ad247ec76be7a60bc1cf9d3abbb9e7f1 | |
- name: run unit tests | |
id: unitTest | |
run: ./gradlew $GRADLEW_UNIT_TEST_ARGS -Dorg.gradle.parallel=true -Dorg.gradle.caching=true | |
- name: Publish Test Report | |
uses: mikepenz/action-junit-report@5f47764eec0e1c1f19f40c8e60a5ba47e47015c5 | |
if: success() || failure() # always run even if the build step fails | |
with: | |
report_paths: '**/test-results/**/TEST-*.xml' | |
annotate_only: true | |
unittests-passed: | |
runs-on: ubuntu-22.04 | |
needs: [unitTests] | |
permissions: | |
checks: write | |
statuses: write | |
steps: | |
- name: consolidation | |
run: echo "consolidating statuses" |