Add migrations to custom field travis build

refs #402
This commit is contained in:
Julien Fastré 2015-01-30 18:29:34 +01:00
parent 9e8374bef7
commit 6c4851134d
4 changed files with 37 additions and 24 deletions

View File

@ -1,28 +1,26 @@
language: php
php:
- 5.5
- 5.6
- hhvm-nightly
- 5.5
- 5.6
- hhvm-nightly
matrix:
allow_failures:
- php: hhvm-nightly
addons:
postgresql: "9.3"
postgresql: '9.3'
install:
- composer config -g github-oauth.github.com $GITHUB_COMPOSER_AUTH
- composer install --dev
- cp Tests/Fixtures/App/app/config/parameters.travis.yml Tests/Fixtures/App/app/config/parameters.yml
before_script:
- psql -c 'create database test0;' -U postgres
- cp Tests/Fixtures/App/app/config/parameters.travis.yml Tests/Fixtures/App/app/config/parameters.yml
- ./console.sh --env=test cache:warmup
- ./console.sh doctrine:schema:create --no-interaction --env=test
- ./console.sh doctrine:fixtures:load --no-interaction --env=test
install:
- composer install --dev
- "./console.sh --env=test cache:warmup"
- "./console.sh doctrine:migrations:migrate --no-interaction"
- "./console.sh doctrine:fixtures:load --no-interaction --env=test"
script: phpunit --coverage-text
notifications:
email:
- info@champs-libres.coop
env:
global:
secure: MoVsISTKaeamuFNoylDv/nM6NBXBtCoH5tuGwX3RHpRK/zRXh421RgO8z/GTHxGt63r04EfYrsCXXng8fN4ZVA2Bjb9chGAozYZJOSwZ9Vmfjycu3k0v/+hikAj33DT+CEdVk4fggEZh5dcVbaJDRgaUZkwMLUtyCqeiv+J5X68=

View File

@ -15,7 +15,8 @@ class AppKernel extends Kernel
new \Symfony\Bundle\AsseticBundle\AsseticBundle(),
new Doctrine\Bundle\DoctrineBundle\DoctrineBundle(),
new \Chill\MainBundle\ChillMainBundle,
new \Doctrine\Bundle\FixturesBundle\DoctrineFixturesBundle()
new \Doctrine\Bundle\FixturesBundle\DoctrineFixturesBundle(),
new Doctrine\Bundle\MigrationsBundle\DoctrineMigrationsBundle()
#add here all the required bundle (some bundle are not required)
);
}

View File

@ -0,0 +1,2 @@
*
!.gitignore

View File

@ -28,7 +28,13 @@
"symfony/monolog-bundle": "~2.4",
"sensio/distribution-bundle": "~3.0",
"sensio/framework-extra-bundle": "~3.0",
"chill-project/main": "*@dev"
"chill-project/main": "*@dev",
"champs-libres/composer-bundle-migration": "~1.0",
"doctrine/doctrine-migrations-bundle": "dev-master@dev",
"doctrine/migrations": "~1.0@dev"
},
"require-dev": {
"doctrine/doctrine-fixtures-bundle": "~2.2@dev"
},
"scripts": {
"post-install-cmd": [
@ -38,10 +44,16 @@
"Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::buildBootstrap"
]
},
"extra": {
"symfony-app-dir": "Tests/Fixtures/App/app"
"scripts": {
"post-install-cmd": [
"ComposerBundleMigration\\Composer\\Migrations::synchronizeMigrations"
],
"post-update-cmd": [
"ComposerBundleMigration\\Composer\\Migrations::synchronizeMigrations"
]
},
"require-dev": {
"doctrine/doctrine-fixtures-bundle": "~2.2@dev"
"extra": {
"symfony-app-dir": "Tests/Fixtures/App/app",
"app-migrations-dir": "Tests/Fixtures/App/app/DoctrineMigrations"
}
}