name: Android CI
on: 
  pull_request:
  workflow_dispatch:
jobs:
  unit_test_report:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout code
        uses: actions/checkout@v2

      - name: set up JDK 11
        uses: actions/setup-java@v2
        with:
          distribution: 'zulu'
          java-version: 11

      # Execute unit tests
      - name: Unit Test
        run: ./gradlew testDebugUnitTest

      - name: Archive code coverage results
        uses: actions/upload-artifact@v2
        with:
          name: code-coverage-report
          path: build/reports/tests/testDebugUnitTest/index.html
          retention-days: 1
        if: ${{ always() }} # IMPORTANT: run always regardless of previous jobs status

name: Android CI
on: 
  pull_request:
  workflow_dispatch:
jobs:
  unit_test_report:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout code
        uses: actions/checkout@v2

      - name: set up JDK 11
        uses: actions/setup-java@v2
        with:
          distribution: 'zulu'
          java-version: 11

      # Execute unit tests
      - name: Unit Test
        run: ./gradlew testDebugUnitTest

      - name: Archive code coverage results
        uses: actions/upload-artifact@v2
        with:
          name: code-coverage-report
          path: build/reports/tests/testDebugUnitTest/*
          retention-days: 1
          if-no-files-found: error
        if: ${{ always() }} # IMPORTANT: run always regardless of previous jobs status


Update path and fail if no test results are present
Update path and fail if no test results are present
