Skip to content

chore: update workflows #58

chore: update workflows

chore: update workflows #58

Workflow file for this run

name: ci
on:
pull_request:
push:
branches:
- main
permissions:
contents: read
env:
GO_VERSION: 1.23
jobs:
tests:
runs-on: ubuntu-latest
services:
mysql:
image: mysql:8.0
env:
MYSQL_ALLOW_EMPTY_PASSWORD: yes
MYSQL_DATABASE: mysql
MYSQL_USER: mysql
MYSQL_PASSWORD: mysql
MYSQL_HOST: 127.0.0.1
ports:
- 3306:3306
options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3
steps:
- name: checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
- name: setup Go environment
uses: actions/setup-go@0aaccfd150d50ccaeb58ebd88d36e91967a5f35b # v5.4.0
with:
go-version: ${{ env.GO_VERSION }}
cache-dependency-path: "**/*.sum"
- name: Test
run: go test -v ./...
- name: Integration tests
run: go test -v ./...
env:
INTEGRATION_TESTS: "true"
MYSQL_URL: "mysql:mysql@tcp(127.0.0.1:3306)/mysql"