SchildiChat-android/.github/workflows/tests.yml
ariskotsomitopoulos fe1d9aa589 - Optimize build time for local builds
- Enhance CI/CD workflows (7GB Ram, 2CPU) by adding custom gradle arguments to properly run
- Add unit test UI comment representation plugin
2021-09-13 19:03:35 +03:00

35 lines
970 B
YAML

name: Test
on:
pull_request: {}
push:
branches: [main, develop]
# Enrich gradle.properties for CI/CD
env:
CI_GRADLE_ARG_PROPERTIES: >
-Porg.gradle.jvmargs=-Xmx2g
-Porg.gradle.parallel=false
jobs:
unit-tests:
name: Run Unit Tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/cache@v2
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: Run unit tests
run: ./gradlew clean test $CI_GRADLE_ARG_PROPERTIES -PallWarningsAsErrors=false --stacktrace
- name: Publish Unit Test Results
uses: EnricoMi/publish-unit-test-result-action@v1
if: always()
with:
files: ./**/build/test-results/**/*.xml
# files: test-results/**/*.xml