mirror of
https://github.com/jlengrand/atrium.git
synced 2026-03-10 08:01:19 +00:00
It is very unlikely someone uses JS with jasmine as jetbrains has setup everything with mocha
60 lines
1.9 KiB
YAML
60 lines
1.9 KiB
YAML
name: Samples
|
|
|
|
on:
|
|
push:
|
|
paths:
|
|
- 'samples/**'
|
|
pull_request:
|
|
paths:
|
|
- 'samples/**'
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: windows-latest
|
|
strategy:
|
|
fail-fast: true
|
|
matrix:
|
|
java_version: [9, 10, 11, 12, 13, 14]
|
|
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: "Set up JDK ${{ matrix.java_version }}"
|
|
uses: actions/setup-java@v1
|
|
with:
|
|
java-version: ${{ matrix.java_version }}
|
|
|
|
- name: Cache maven dependencies
|
|
uses: actions/cache@v1
|
|
with:
|
|
path: ~/.m2/repository
|
|
key: samples-${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
|
|
restore-keys: |
|
|
samples-${{ runner.os }}-maven-
|
|
|
|
- name: build js sample
|
|
run: ./gradlew build
|
|
working-directory: samples\js
|
|
|
|
- name: build Spek sample
|
|
run: ./gradlew build
|
|
working-directory: samples\jvm\spek
|
|
|
|
- name: build Junit5 sample
|
|
run: ./gradlew build
|
|
working-directory: samples\jvm\junit5
|
|
|
|
- name: build MPP sample
|
|
run: ./gradlew build
|
|
working-directory: samples\multiplatform
|
|
|
|
# Kotlin does not yet support to generate jdk 14 byte code
|
|
- name: determine kotlin compile target
|
|
run: |
|
|
export KOTLIN_TARGET=$(if [ "${{ matrix.java_version }}" -eq "14" ]; then echo "13"; else echo "${{ matrix.java_version }}"; fi)
|
|
echo "::set-env name=KOTLIN_TARGET::$KOTLIN_TARGET"
|
|
shell: bash
|
|
|
|
- name: build maven sample
|
|
run: ./mvnw -B clean verify "-Djava.version=${{ env.KOTLIN_TARGET }}"
|
|
working-directory: samples/maven
|