Skip to content

Commit

Permalink
switch from Travis to GitHub actions (#113)
Browse files Browse the repository at this point in the history
  • Loading branch information
JanTvrdik authored Dec 19, 2020
1 parent 6d5983d commit f687a65
Show file tree
Hide file tree
Showing 5 changed files with 71 additions and 44 deletions.
68 changes: 68 additions & 0 deletions .github/workflows/qa.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
name: QA

on:
pull_request:
branches:
- master

push:
branches:
- master
- v*

jobs:
tests:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php: ['5.4', '5.5', '5.6', '7.0', '7.1', '7.2', '7.3', '7.4', '8.0']

name: PHP ${{ matrix.php }}

services:
postgres:
image: postgres:9.6
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: nextras_migrations_test
ports:
- 5432:5432
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
mysql:
image: mysql:5.6
env:
MYSQL_DATABASE: nextras_migrations_test
MYSQL_ROOT_PASSWORD: root
ports:
- 3306:3306
options: >-
--health-cmd "mysqladmin ping -ppass"
--health-interval 10s
--health-start-period 10s
--health-timeout 5s
--health-retries 10
steps:
- uses: actions/checkout@v2
- uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: json, ctype, mysqli, pgsql, pdo_mysql, pdo_pgsql
coverage: none

- name: Prepare Env
run: |
PHP_DIR=$(php -r 'echo dirname(php_ini_loaded_file());')
cat $PHP_DIR/php.ini $PHP_DIR/conf.d/*.ini > ./tests/php.ini
cp ./tests/drivers.sample.ini ./tests/drivers.ini
composer install --no-interaction --no-progress
- run: tests/run-unit.sh
- run: tests/run-integration.sh
41 changes: 0 additions & 41 deletions .travis.yml

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@ migrations:
diffGenerator: doctrine

services:
- Doctrine\ORM\Tools\Setup::createAnnotationMetadataConfiguration([%doctrineDir%])
- Doctrine\ORM\Tools\Setup::createAnnotationMetadataConfiguration([%doctrineDir%], true)
- Doctrine\DBAL\DriverManager::getConnection(%doctrineConfig%, @Doctrine\ORM\Configuration)
- Doctrine\ORM\EntityManager::create(@Doctrine\DBAL\Connection, @Doctrine\ORM\Configuration)
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@ migrations:
driver: mysql

services:
- Doctrine\ORM\Tools\Setup::createAnnotationMetadataConfiguration([%doctrineDir%])
- Doctrine\ORM\Tools\Setup::createAnnotationMetadataConfiguration([%doctrineDir%], true)
- Doctrine\DBAL\DriverManager::getConnection(%doctrineConfig%, @Doctrine\ORM\Configuration)
- Doctrine\ORM\EntityManager::create(@Doctrine\DBAL\Connection, @Doctrine\ORM\Configuration)
2 changes: 1 addition & 1 deletion tests/drivers.sample.ini
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
host = "127.0.0.1"
database = nextras_migrations_test
username = root
password =
password = root

[pgsql]
host = "127.0.0.1"
Expand Down

0 comments on commit f687a65

Please sign in to comment.