Skip to content

Bump actions/checkout from 3.5.2 to 3.6.0 #262

Bump actions/checkout from 3.5.2 to 3.6.0

Bump actions/checkout from 3.5.2 to 3.6.0 #262

Workflow file for this run

name: MySQL tests
on: [ push ]
permissions: # added using https://github.com/step-security/secure-workflows
contents: read
jobs:
Test-mysql-integration:
runs-on: ubuntu-latest
services:
mysql:
image: mysql:8
env:
MYSQL_DATABASE: libschematest
MYSQL_ROOT_PASSWORD: mysql
options: >-
--health-cmd "mysqladmin ping"
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 3306:3306
steps:
- name: Harden Runner
uses: step-security/harden-runner@128a63446a954579617e875aaab7d2978154e969
with:
# egress-policy: audit # TODO: change to 'egress-policy: block' after couple of runs
egress-policy: block
allowed-endpoints: >
api.github.com:443
codecov.io:443
github.com:443
go.dev:443
golang.org:443
proxy.golang.org:443
storage.googleapis.com:443
uploader.codecov.io:443
- name: Check out repository code
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744
- name: Set up Go
uses: actions/setup-go@4d34df0c2316fe8122ab82dc22947d607c0c91f9
with:
go-version: 1.16
- name: Build
run: go build -v ./...
- name: Test
env:
LIBSCHEMA_MYSQL_TEST_DSN: "root:mysql@tcp(127.0.0.1:3306)/libschematest?tls=false"
run: go test ./lsmysql/... -v
- name: Run Coverage
env:
LIBSCHEMA_MYSQL_TEST_DSN: "root:mysql@tcp(127.0.0.1:3306)/libschematest?tls=false"
run: go test -coverprofile=coverage.txt -covermode=atomic -coverpkg=github.com/muir/libschema/... ./lsmysql/...
- name: Upload coverage to Codecov
uses: codecov/codecov-action@894ff025c7b54547a9a2a1e9f228beae737ad3c2
with:
verbose: true
flags: mysql_tests
fail_ci_if_error: true