mirror of
https://github.com/yairm210/Unciv.git
synced 2025-01-08 14:33:42 +07:00
36 lines
783 B
YAML
36 lines
783 B
YAML
# Jobs to test the code base and build the client and server app
|
|
name: Build and test
|
|
|
|
on:
|
|
# Triggers the workflow on any push or pull request
|
|
push:
|
|
pull_request:
|
|
|
|
jobs:
|
|
|
|
# We only need the minimum
|
|
|
|
code-checks:
|
|
name: Check code and run unit tests
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
|
|
- uses: actions/setup-java@v3
|
|
with:
|
|
cache: 'gradle'
|
|
distribution: 'temurin'
|
|
java-version: 11
|
|
|
|
- name: Setup Gradle
|
|
uses: gradle/gradle-build-action@v2.4.0
|
|
|
|
- name: Compile kotlin and build classes
|
|
run: ./gradlew classes
|
|
|
|
- name: Run code checks
|
|
run: ./gradlew check
|
|
|
|
- name: Run unit tests
|
|
run: ./gradlew --no-build-cache cleanTest test tests:test
|