Skip to content

fix: update backend check for caching shared subscriptions (#95) #677

fix: update backend check for caching shared subscriptions (#95)

fix: update backend check for caching shared subscriptions (#95) #677

Workflow file for this run

name: checks format & runs tests
on:
push:
branches:
- 'main'
pull_request:
release:
types:
- published
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
env:
# Default OTP version used for current releases
DEFAULT_RELEASE_OTP: 27.3.4.1
jobs:
code_checks:
name: Check code style and quality
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: erlef/setup-beam@v1.18.2
with:
otp-version: ${{ env.DEFAULT_RELEASE_OTP }}
version-type: strict
- run: sudo apt-get -y install libsnappy-dev
- name: Check code formatting (erlfmt)
run: ./rebar3 fmt -c
- name: Run dialyzer type checker
run: ./rebar3 dialyzer
continue-on-error: true
coverage:
name: Test on ${{ matrix.os }} with OTP ${{ matrix.otp }}
runs-on: ${{ matrix.os }}
timeout-minutes: 60
needs: code_checks
strategy:
fail-fast: false
matrix:
os:
- ubuntu-24.04
- ubuntu-22.04
otp:
- "27.3.4.1"
- "26.2.5.13"
- "25.3.2.21"
services:
postgres:
image: postgres
ports:
- 5432:5432
env:
POSTGRES_USER: vmq_test_user
POSTGRES_PASSWORD: vmq_test_password
POSTGRES_DB: vmq_test_database
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
memcached:
image: memcached
ports:
- 11211:11211
redis:
image: redis
ports:
- 6379:6379
options: >-
--health-cmd "redis-cli ping"
--health-interval 10s
--health-timeout 5s
--health-retries 5
redissentinel:
image: bitnamilegacy/redis-sentinel
ports:
- 26379:26379
options: >-
--health-cmd "redis-cli -p 26379 ping"
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
- uses: actions/checkout@v4
- uses: erlef/setup-beam@v1.18.2
with:
otp-version: ${{ matrix.otp }}
version-type: strict
- run: sudo apt-get -y install libsnappy-dev
- run: sudo apt-get -y install pcregrep
- run: make rel
- run: make db-setup
- run: pwd
- run: sh ./run-tests-with-retry.sh .