mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-08 00:47:55 +08:00
application tests have been moved to their own repo
This commit is contained in:
22
.travis.yml
22
.travis.yml
@ -61,8 +61,6 @@ install:
|
|||||||
# - tests/unit/data/travis/cubrid-setup.sh
|
# - tests/unit/data/travis/cubrid-setup.sh
|
||||||
# codeception
|
# codeception
|
||||||
- travis_retry composer global require "codeception/codeception=2.0.*" "codeception/specify=*" "codeception/verify=*"
|
- travis_retry composer global require "codeception/codeception=2.0.*" "codeception/specify=*" "codeception/verify=*"
|
||||||
# basic and advanced application:
|
|
||||||
- tests/unit/data/travis/setup-apps.sh
|
|
||||||
|
|
||||||
before_script:
|
before_script:
|
||||||
# show some versions and env information
|
# show some versions and env information
|
||||||
@ -76,8 +74,6 @@ before_script:
|
|||||||
- psql -U postgres -c 'CREATE DATABASE yiitest;';
|
- psql -U postgres -c 'CREATE DATABASE yiitest;';
|
||||||
- tests/unit/data/travis/sphinx-setup.sh
|
- tests/unit/data/travis/sphinx-setup.sh
|
||||||
- mongo yii2test --eval 'db.addUser("travis", "test");'
|
- mongo yii2test --eval 'db.addUser("travis", "test");'
|
||||||
# basic and advanced application:
|
|
||||||
- tests/unit/data/travis/init-apps.sh
|
|
||||||
- |
|
- |
|
||||||
if [ $TRAVIS_PHP_VERSION = '5.6' ]; then
|
if [ $TRAVIS_PHP_VERSION = '5.6' ]; then
|
||||||
PHPUNIT_FLAGS="--coverage-clover=coverage.clover"
|
PHPUNIT_FLAGS="--coverage-clover=coverage.clover"
|
||||||
@ -86,24 +82,6 @@ before_script:
|
|||||||
|
|
||||||
script:
|
script:
|
||||||
- vendor/bin/phpunit --verbose $PHPUNIT_FLAGS --exclude-group mssql,oci,wincache,xcache,zenddata
|
- vendor/bin/phpunit --verbose $PHPUNIT_FLAGS --exclude-group mssql,oci,wincache,xcache,zenddata
|
||||||
- |
|
|
||||||
if (php --version | grep -i HipHop > /dev/null); then
|
|
||||||
echo "Skipping basic application tests on HHVM"
|
|
||||||
else
|
|
||||||
cd apps/basic/web
|
|
||||||
php -S localhost:8080 > /dev/null 2>&1 &
|
|
||||||
cd ../tests
|
|
||||||
codecept run
|
|
||||||
fi
|
|
||||||
- |
|
|
||||||
if (php --version | grep -i HipHop > /dev/null); then
|
|
||||||
echo "Skipping advanced application tests on HHVM"
|
|
||||||
else
|
|
||||||
cd apps/advanced
|
|
||||||
php -S localhost:8080 > /dev/null 2>&1 &
|
|
||||||
cd tests
|
|
||||||
codecept run
|
|
||||||
fi
|
|
||||||
|
|
||||||
after_script:
|
after_script:
|
||||||
- |
|
- |
|
||||||
|
|||||||
@ -1,11 +0,0 @@
|
|||||||
#!/bin/sh -e
|
|
||||||
|
|
||||||
if (php --version | grep -i HipHop > /dev/null); then
|
|
||||||
echo "skipping application init on HHVM"
|
|
||||||
else
|
|
||||||
|
|
||||||
mysql -e 'CREATE DATABASE yii2_advanced_tests;';
|
|
||||||
cd apps/advanced/tests/codeception/bin
|
|
||||||
php yii migrate --interactive=0
|
|
||||||
cd ../../../../..
|
|
||||||
fi
|
|
||||||
@ -1,26 +0,0 @@
|
|||||||
#!/bin/sh -e
|
|
||||||
|
|
||||||
if (php --version | grep -i HipHop > /dev/null); then
|
|
||||||
echo "skipping application setup on HHVM"
|
|
||||||
else
|
|
||||||
|
|
||||||
# basic application:
|
|
||||||
|
|
||||||
composer install --dev --prefer-dist -d apps/basic
|
|
||||||
cd apps/basic && sed -i "s/'cookieValidationKey' => ''/'cookieValidationKey' => 'testkey'/" config/web.php
|
|
||||||
cd tests && codecept build && cd ../../..
|
|
||||||
|
|
||||||
|
|
||||||
# advanced application:
|
|
||||||
|
|
||||||
composer install --dev --prefer-dist -d apps/advanced
|
|
||||||
cd apps/advanced && ./init --env=Development
|
|
||||||
sed -i s/root/travis/ common/config/main-local.php
|
|
||||||
sed -i "s/'cookieValidationKey' => ''/'cookieValidationKey' => 'testkey'/" frontend/config/main.php
|
|
||||||
sed -i "s/'cookieValidationKey' => ''/'cookieValidationKey' => 'testkey'/" backend/config/main.php
|
|
||||||
cd tests/codeception/backend && codecept build
|
|
||||||
cd ../common && codecept build
|
|
||||||
cd ../console && codecept build
|
|
||||||
cd ../frontend && codecept build
|
|
||||||
cd ../../../
|
|
||||||
fi
|
|
||||||
Reference in New Issue
Block a user