Merge pull request #105 from JNU-econovation/feature/BE-40 #16
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
# 디밸롭 메인 브런치의 총 테스트 커버리지 측정을 위한 ci workflow | |
name: develop-branch-test-coverage | |
on: | |
push: | |
branches: | |
- develop | |
- backend | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
java-version: [ 11 ] | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: SetUp JDK 11 | |
uses: actions/setup-java@v2 | |
with: | |
java-version: "11" | |
distribution: 'adopt' | |
- name: Cache SonarCloud packages | |
uses: actions/cache@v3 | |
with: | |
path: ~/.sonar/cache | |
key: ${{ runner.os }}-sonar | |
restore-keys: ${{ runner.os }}-sonar | |
- name: Cache Gradle packages | |
uses: actions/cache@v3 | |
with: | |
path: ~/.gradle/caches | |
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }} | |
restore-keys: ${{ runner.os }}-gradle | |
- name: test | |
run: ./server/gradlew test --info --stacktrace --no-daemon | |
- name: analyze | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} | |
run: ./server/gradlew sonar --info --stacktrace --no-daemon |