Skip to content

Refactor : remove jacoco report temporarily (#26912) #95

Refactor : remove jacoco report temporarily (#26912)

Refactor : remove jacoco report temporarily (#26912) #95

Workflow file for this run

#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
name: CI
on:
push:
branches: [ master, dev ]
paths:
- '.github/workflows/ci.yml'
- '**/pom.xml'
- '**/src/main/**'
- '**/src/test/**'
- '!distribution/**'
- 'test/it/**'
- '!test/e2e/**'
- 'test/e2e/driver/**'
- '!*.md'
pull_request:
branches: [ master ]
paths:
- '.github/workflows/ci.yml'
- '**/pom.xml'
- '**/src/main/**'
- '**/src/test/**'
- '!distribution/**'
- 'test/it/**'
- '!test/e2e/**'
- 'test/e2e/driver/**'
- '!*.md'
repository_dispatch:
types: [ci-completed]
workflow_dispatch:
concurrency:
group: ${{ github.event_name }}-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
MAVEN_OPTS: -Dhttp.keepAlive=false -Dmaven.wagon.http.pool=false -Dmaven.wagon.http.retryHandler.class=standard -Dmaven.wagon.http.retryHandler.count=3 -Dcheckstyle.skip=true -Dspotless.apply.skip=true -Dmaven.javadoc.skip=true -Djacoco.skip=true
REPOSITORY_NAME: shardingsphere
jobs:
ci:
name: CI - Compile by JDK 11 and Run on JDK 8
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: 11
- uses: actions/cache@v3
with:
path: ~/.m2/repository
key: ${{ env.REPOSITORY_NAME }}-maven-third-party-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ env.REPOSITORY_NAME }}-maven-third-party-
- name: Build prod with Maven
run: ./mvnw -T1C -B -ntp clean install
- name: Setup JDK 8 for Test
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: 8
- name: Run tests with JDK 8
run: ./mvnw -T1C -B -ntp -fae test
test-coverage:
if: github.repository == 'apache/shardingsphere'
name: Test coverage report on JDK ${{ matrix.java-version }}
runs-on: ubuntu-latest
strategy:
matrix:
java-version: [ 11, 20 ]
steps:
- uses: actions/checkout@v3
- name: Cache Maven Repos
uses: actions/cache@v3
with:
path: ~/.m2/repository
key: ${{ env.REPOSITORY_NAME }}-maven-third-party-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ env.REPOSITORY_NAME }}-maven-third-party-
- uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: ${{ matrix.java-version }}
- name: Build with Maven
run: ./mvnw -T1C -B -ntp clean install -DskipTests
- name: Upload to Codecov
run: bash <(curl -s https://codecov.io/bash)