Skip to content

GDPR

GDPR #2280

Workflow file for this run

name: 'Tests'
on:
pull_request:
push:
branches:
- '**'
tags-ignore:
- '*.*'
jobs:
run:
name: "Monorepo"
runs-on: ${{ matrix.operating-system }}
strategy:
matrix:
operating-system: [ ubuntu-latest ]
php-versions: [ '8.0', '8.3' ]
stability: [prefer-stable]
services:
rabbitmq:
image: rabbitmq:3.11-management-alpine
env:
RABBITMQ_DEFAULT_USER: guest
RABBITMQ_DEFAULT_PASS: guest
ports:
- 5672:5672
mysql:
image: mysql:8.0
env:
MYSQL_ROOT_PASSWORD: "secret"
MYSQL_USER: "ecotone"
MYSQL_PASSWORD: "secret"
MYSQL_DATABASE: "ecotone"
DB_PORT: 3306
options: >-
--health-cmd="mysqladmin ping"
--health-interval=10s
--health-timeout=5s
--health-retries=3
ports:
- 3306:3306
postgres:
image: simplycodedsoftware/postgres:16.1
env:
POSTGRES_USER: ecotone
POSTGRES_PASSWORD: secret
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 5432:5432
localstack:
image: localstack/localstack:2.2.0
env:
SERVICES: 'sqs,sns'
ports:
- "4566:4566"
- "4510-4559:4510-4559"
redis:
image: redis:7-alpine
ports:
- '6379:6379'
env:
RABBIT_HOST: amqp://127.0.0.1:5672
SQS_DSN: sqs:?key=key&secret=secret&region=us-east-1&endpoint=http://127.0.0.1:4566&version=latest
REDIS_DSN: redis://127.0.0.1:6379
steps:
- name: PHP ${{ matrix.php-versions }} - ${{ matrix.stability }}
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-versions }}
extensions: grpc
coverage: pcov
- uses: actions/checkout@v2
- name: Validate composer.json and composer.lock
run: composer validate --strict
- name: Install dependencies
run: composer update --${{ matrix.stability }} --prefer-dist --no-interaction
- name: Validate cross package versions
run: vendor/bin/monorepo-builder validate
- name: Test PHPStan
run: vendor/bin/phpstan
- name: Test PHPUnit on Postgres
run: vendor/bin/phpunit
env:
DATABASE_DSN: pgsql://ecotone:secret@127.0.0.1:5432/ecotone
SECONDARY_DATABASE_DSN: mysql://ecotone:secret@127.0.0.1:3306/ecotone
APP_DB_HOST: 127.0.0.1
APP_DB_PORT: 5432
APP_DB_DRIVER: pdo_pgsql
- name: Test Behat on Postgres
run: vendor/bin/behat -vvv
env:
DATABASE_DSN: pgsql://ecotone:secret@127.0.0.1:5432/ecotone
SECONDARY_DATABASE_DSN: mysql://ecotone:secret@127.0.0.1:3306/ecotone
APP_DB_HOST: 127.0.0.1
APP_DB_PORT: 5432
APP_DB_DRIVER: pdo_pgsql
- name: Test PHPUnit on Mysql
run: vendor/bin/phpunit
env:
DATABASE_DSN: mysql://ecotone:secret@127.0.0.1:3306/ecotone
SECONDARY_DATABASE_DSN: pgsql://ecotone:secret@127.0.0.1:5432/ecotone
APP_DB_HOST: 127.0.0.1
APP_DB_PORT: 3306
APP_DB_DRIVER: pdo_mysql
- name: Test Behat on Mysql
run: vendor/bin/behat -vvv
env:
DATABASE_DSN: mysql://ecotone:secret@127.0.0.1:3306/ecotone
SECONDARY_DATABASE_DSN: pgsql://ecotone:secret@127.0.0.1:5432/ecotone
APP_DB_HOST: 127.0.0.1
APP_DB_PORT: 3306
APP_DB_DRIVER: pdo_mysql