From 0d47907cfc92768e51ca3a18bc9e34158cd70ba1 Mon Sep 17 00:00:00 2001 From: Maarten Mulders Date: Mon, 22 May 2023 21:03:52 +0200 Subject: [PATCH] chore(build): Skip tests as part of building the binaries Setting up a macOS runner and a Windows runner that have a GUI is probably going to take ages. --- .github/workflows/early-access.yml | 10 ++++++++-- .github/workflows/release.yml | 12 ++++++++---- 2 files changed, 16 insertions(+), 6 deletions(-) diff --git a/.github/workflows/early-access.yml b/.github/workflows/early-access.yml index b15bab92..93c2662d 100644 --- a/.github/workflows/early-access.yml +++ b/.github/workflows/early-access.yml @@ -73,6 +73,10 @@ jobs: echo "TOOLCHAIN_DIR=$TOOLCHAIN_DIR" >> $GITHUB_OUTPUT if: matrix.os == 'ubuntu-latest' + - name: Install xvfb for headless unit tests + run: sudo apt install xvfb + if: matrix.os == 'ubuntu-latest' + - name: Cache Maven packages uses: actions/cache@v3 with: @@ -82,14 +86,16 @@ jobs: - name: Build static native image for Linux run: | - PATH=${TOOLCHAIN_DIR}/bin:$PATH; mvn -B -Pnative package + PATH=${TOOLCHAIN_DIR}/bin:$PATH; xvfb-run mvn -B -Pnative package env: TOOLCHAIN_DIR: ${{ steps.prepare-musl.outputs.TOOLCHAIN_DIR }} if: matrix.os == 'ubuntu-latest' - name: Build static native image for Windows / macOS run: | - mvn -B -Pnative package + # Yikes, skipTests?! Well, we run those tests on the Ubuntu runner, which should be enough. + # Setting up a macOS runner and a Windows runner that have a GUI is probably going to take ages. + mvn -B -Pnative package -DskipTests if: matrix.os != 'ubuntu-latest' - name: Create distribution diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 40b60076..fd77b786 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -132,6 +132,10 @@ jobs: echo "TOOLCHAIN_DIR=$TOOLCHAIN_DIR" >> $GITHUB_OUTPUT if: matrix.os == 'ubuntu-latest' + - name: Install xvfb for headless unit tests + run: sudo apt install xvfb + if: matrix.os == 'ubuntu-latest' + - name: Cache Maven packages uses: actions/cache@v3 with: @@ -141,16 +145,16 @@ jobs: - name: Build static native image for Linux run: | - # Yikes, skipTests?! Well, we run those tests on the Ubuntu runner, which should be enough. - # Setting up a macOS runner and a Windows runner that have a GUI is probably going to take ages. - PATH=${TOOLCHAIN_DIR}/bin:$PATH; mvn -B -Pnative package -DskipTests + PATH=${TOOLCHAIN_DIR}/bin:$PATH; xvfb-run mvn -B -Pnative package env: TOOLCHAIN_DIR: ${{ steps.prepare-musl.outputs.TOOLCHAIN_DIR }} if: matrix.os == 'ubuntu-latest' - name: Build static native image for Windows / macOS run: | - mvn -B -Pnative package + # Yikes, skipTests?! Well, we run those tests on the Ubuntu runner, which should be enough. + # Setting up a macOS runner and a Windows runner that have a GUI is probably going to take ages. + mvn -B -Pnative package -DskipTests if: matrix.os != 'ubuntu-latest' - name: Create distribution