Skip to content

Return the service file to last known fully working #137

Return the service file to last known fully working

Return the service file to last known fully working #137

Workflow file for this run

name: Platform Tests
on: [push, pull_request]
jobs:
platform_tests:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
go-version: ['1.19', '1.23']
os: [ubuntu-latest]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
id: setup-go-faster
with:
go-version: ${{ matrix.go-version }}
- name: Get dependencies
run: sudo apt-get update && sudo apt-get install gcc libgl1-mesa-dev libegl1-mesa-dev libgles2-mesa-dev libx11-dev xorg-dev libpam-dev bc
if: ${{ runner.os == 'Linux' }}
- name: Tests
run: go test -tags ci ./...
- name: Update coverage
run: |
go install github.com/mattn/goveralls@latest
set -e
go test -tags ci -covermode=atomic -coverprofile=coverage.out ./...
coverage=`go tool cover -func coverage.out | grep total | tr -s '\t' | cut -f 3 | grep -o '[^%]*'`
if (( $(echo "$coverage < 20" | bc) )) ; then echo "Test coverage lowered"; exit 1; fi
if: ${{ runner.os == 'Linux' }}
- name: Update PR Coverage
uses: shogo82148/actions-goveralls@v1
with:
path-to-profile: coverage.out
if: ${{ runner.os == 'Linux' && matrix.go-version == '1.19' && github.event_name == 'push' }}