Skip to content
Snippets Groups Projects
test.yml 5.74 KiB
name: Test

on:
  push:
  pull_request:
  workflow_dispatch:

jobs:
#===================================#
#               JAVA                #
#===================================#
  gradle:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - name: Set up JDK 8
        uses: actions/setup-java@v3
        with:
          distribution: 'adopt'
          java-version: '8'
      - name: Where is Java
        run: which java
      - name: Grant execute permission for gradlew
        run: chmod +x gradlew
      - name: Build with Gradle
        run: ./gradlew about installQuasar cleanFrontend assembleFrontend copyDist build --info
      - name: List files in libs
        run: ls -ahl build/libs
      - uses: actions/upload-artifact@v3
        with:
          name: build-artifacts-gradle
          path: |
            build/libs/
            !build/libs/libraries/
          if-no-files-found: warn # 'warn' or 'ignore' are also available, defaults to `warn`
      - uses: actions/upload-artifact@v3
        if: failure()
        with:
          name: gradle-report
          path: build/reports/tests/test/
          if-no-files-found: warn # 'warn' or 'ignore' are also available, defaults to `warn`

#===================================#
#              QUASAR               #
#===================================#
  quasar:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - name: Setup Node.js environment
        uses: actions/setup-node@v3.0.0
        with:
          # Version Spec of the version to use.  Examples: 12.x, 10.15.1, >=10.15.0
          node-version: '>= 16.13.1'
          # Set this option if you want the action to check for the latest available version that satisfies the version spec
          check-latest: false
#      - run: npm install -g @quasar/cli
#      - run: npm install
#      - run: quasar build
#      - run: pwd && ls -al *
#      - uses: actions/upload-artifact@v2
#        with:
#          name: build-artifacts
#          path: dist/spa/ # frontend/dist/spa if Gradle Spring Boot project for example
#          if-no-files-found: warn # 'warn' or 'ignore' are also available, defaults to `warn`
#
#===================================#
#              DOCKER               #
#===================================#
  docker: