diff options
author | Sphyix <masifede2@gmail.com> | 2022-01-21 00:30:28 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-21 00:30:28 +0100 |
commit | 3b12f80a256ce557624ed02354e5ad40bb6a7dd8 (patch) | |
tree | 209cceb66e2e4db19a99da18693e50c610e909a1 /.github/workflows/build-and-test.yml | |
parent | 223bbd822b8656fe4b5d805db71dab4730dc145d (diff) | |
parent | 2f4fc523ab40b1d0bbf8918d2632159d3576c627 (diff) | |
download | GT5-Unofficial-3b12f80a256ce557624ed02354e5ad40bb6a7dd8.tar.gz GT5-Unofficial-3b12f80a256ce557624ed02354e5ad40bb6a7dd8.tar.bz2 GT5-Unofficial-3b12f80a256ce557624ed02354e5ad40bb6a7dd8.zip |
Merge branch 'GTNewHorizons:master' into master
Diffstat (limited to '.github/workflows/build-and-test.yml')
-rw-r--r-- | .github/workflows/build-and-test.yml | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/.github/workflows/build-and-test.yml b/.github/workflows/build-and-test.yml new file mode 100644 index 0000000000..08df9fe89f --- /dev/null +++ b/.github/workflows/build-and-test.yml @@ -0,0 +1,45 @@ +# 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://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle + +name: Build and test + +on: + pull_request: + branches: [ master, main ] + push: + branches: [ master, main ] + +jobs: + build-and-test: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + + - name: Set up JDK 8 + uses: actions/setup-java@v2 + with: + java-version: '8' + distribution: 'adopt' + cache: gradle + + - name: Grant execute permission for gradlew + run: chmod +x gradlew + + - name: Setup the workspace + run: ./gradlew setupCIWorkspace + + - name: Build the mod + run: ./gradlew build + + - name: Run server for 1.5 minutes + run: | + mkdir run + echo "eula=true" > run/eula.txt + timeout 90 ./gradlew runServer | tee --append server.log || true + + - name: Test no errors reported during server run + run: | + chmod +x .github/scripts/test-no-error-reports.sh + .github/scripts/test-no-error-reports.sh |