-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore[sdds-android, cicd]: Project build system migration to composit…
…e builds was made to support multiproject structure. Code quality check workflow was created. Merge reports tasks were added.
- Loading branch information
Showing
70 changed files
with
2,353 additions
and
284 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
name: 'Code Quality Check' | ||
|
||
on: | ||
pull_request: | ||
paths: | ||
- ./native/sdds-android/** | ||
push: | ||
paths: | ||
- ./native/sdds-android/** | ||
|
||
jobs: | ||
lint: | ||
name: Perform static analysis | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout the code | ||
uses: actions/checkout@v2 | ||
|
||
- name: Cache Gradle | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/.gradle/caches | ||
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }} | ||
restore-keys: ${{ runner.os }}-gradle- | ||
|
||
- name: Make Gradle executable | ||
run: chmod +x ./gradlew | ||
|
||
- name: Run lint | ||
run: ./gradlew lintDebugAll | ||
|
||
- name: Run detekt | ||
run: ./gradlew detektAll | ||
|
||
- name: Run spotless | ||
run: ./gradlew spotlessCheckAll | ||
|
||
- name: Merge reports | ||
if: success() || failure() | ||
run: ./gradlew mergeReports | ||
|
||
- name: Upload html test report | ||
if: success() || failure() | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: static_analysis | ||
path: build/reports/ | ||
|
||
unit-test: | ||
name: Perform Unit Testing | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout the code | ||
uses: actions/checkout@v2 | ||
|
||
- name: Run tests | ||
run: ./gradlew test | ||
|
||
- name: Merge test reports | ||
if: success() || failure() | ||
run: ./gradlew copyTestsReports | ||
|
||
- name: Upload test report | ||
if: success() || failure() | ||
uses: actions.upload-artifact@v2 | ||
with: | ||
name: test_reports | ||
path: build/reports/test/ | ||
|
Oops, something went wrong.