Store new desktop app data outside the fyne subdirectory #9302
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Platform Tests | |
| on: [push, pull_request] | |
| permissions: | |
| contents: read | |
| jobs: | |
| platform_tests: | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| go-version: ["", "stable"] | |
| os: [ubuntu-latest, macos-latest, windows-latest] | |
| include: | |
| - os: ubuntu-latest | |
| runner: xvfb-run | |
| tags: ci,migrated_fynedo | |
| cover: -covermode=atomic -coverprofile=coverage.out | |
| - os: macos-latest | |
| tags: no_glfw,ci,migrated_fynedo | |
| - os: windows-latest | |
| tags: no_glfw,migrated_fynedo | |
| steps: | |
| - uses: actions/checkout@v5 | |
| with: | |
| persist-credentials: false | |
| - uses: actions/setup-go@v6 | |
| with: | |
| go-version: ${{ matrix.go-version }} | |
| go-version-file: ${{ matrix.go-version == '' && 'go.mod' || '' }} | |
| - name: Get dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install --no-install-recommends bc clang lld libgl1-mesa-dev libwayland-dev libx11-dev libxkbcommon-dev xorg-dev xvfb language-pack-en fonts-noto-cjk | |
| echo "CC=clang" >> "$GITHUB_ENV" | |
| echo "CGO_LDFLAGS=-fuse-ld=lld" >> "$GITHUB_ENV" | |
| if: ${{ runner.os == 'Linux' }} | |
| - name: Set environment variable LANG | |
| run: echo "LANG=en_US.UTF-8" >> $GITHUB_ENV | |
| if: ${{ runner.os == 'Linux' }} | |
| # Recent macOS (Tahoe/26) requires an LC_UUID load command, which Go's | |
| # internal linker does not emit on older Go versions. Force external | |
| # linking so the test binaries get an LC_UUID and don't abort trap with | |
| # "missing LC_UUID load command". See golang/go#69987 and #78012. | |
| - name: Set macOS linker flag (LC_UUID workaround) | |
| run: echo "TESTLDFLAGS=-ldflags=-linkmode=external" >> $GITHUB_ENV | |
| if: ${{ runner.os == 'macOS' && matrix.go-version == '' }} | |
| - name: Tests | |
| run: ${{ matrix.runner }} go test -race -tags "${{ matrix.tags }}" ${{ matrix.cover }} ${{ env.TESTLDFLAGS }} ./... | |
| - name: Upload failed testdata | |
| uses: actions/upload-artifact@v5 | |
| if: failure() | |
| with: | |
| name: failed-testdata-${{ matrix.os }}-${{ matrix.go-version }} | |
| path: | | |
| **/testdata/failed | |
| retention-days: 1 | |
| if-no-files-found: ignore | |
| - name: Wayland Tests | |
| run: go test -race -tags no_glfw,ci,wayland ./... | |
| if: ${{ runner.os == 'Linux' }} | |
| - name: Update coverage | |
| run: | | |
| set -e | |
| coverage=`go tool cover -func coverage.out | grep total | tr -s '\t' | cut -f 3 | grep -o '[^%]*'` | |
| if (( $(echo "$coverage < 60" | bc) )); then echo "Test coverage lowered"; exit 1; fi | |
| if: ${{ runner.os == 'Linux' && matrix.go-version == 'stable' }} | |
| - name: Update PR Coverage | |
| uses: shogo82148/actions-goveralls@v1 | |
| with: | |
| path-to-profile: coverage.out | |
| if: ${{ runner.os == 'Linux' && matrix.go-version == 'stable' }} |