Skip to content

Adding code for the App #1

Adding code for the App

Adding code for the App #1

Workflow file for this run

# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
# This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-java-with-gradle
name: Build and test
on:
push:
branches: [ "dev" ]
pull_request:
branches: [ "main" ]
jobs:
# Build job
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'
cache: gradle
- name: Grant execute permissio for gradlew
run: chmod +x gradlew
- name: Build with Gradle
run: ./gradlew build
# Test job:
test:
runs-on: ubuntu-latest
needs: build
steps:
- uses: actions/checkout@v3
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'
cache: gradle
- name: Grant execute permissio for gradlew
run: chmod +x gradlew
- name: Run linter and test
run: ./gradlew check
- name: Upload artifacts
uses: actions/upload-artifact@v3
with:
name: Test-Reports
path: app/build/Test-Reports