-
-
Notifications
You must be signed in to change notification settings - Fork 338
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #851 from phalcon/3.3.x
3.3.0
- Loading branch information
Showing
85 changed files
with
1,628 additions
and
1,383 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,9 @@ | ||
.DS_Store | ||
.idea/* | ||
*.sublime-project | ||
*.sublime-workspace | ||
# Please do not use this ignore file to define platform specific files. | ||
# | ||
# For these purposes create a global .gitignore file, which is a list of rules | ||
# for ignoring files in every Git repository on your computer. | ||
# | ||
# https://help.github.com/articles/ignoring-files/#create-a-global-gitignore | ||
|
||
composer.lock | ||
composer.phar | ||
/nbproject/ | ||
/vendor/ | ||
.vagrant | ||
Vagrantfile | ||
/build | ||
/tests/_support/_generated/*.php |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
# Phalcon Framework | ||
# | ||
# Copyright (c) 2011-2017 Phalcon Team (https://www.phalconphp.com) | ||
# Copyright (c) 2011-2018 Phalcon Team (https://www.phalconphp.com) | ||
# | ||
# This source file is subject to the New BSD License that is bundled | ||
# with this package in the file LICENSE.txt. | ||
|
@@ -11,99 +11,79 @@ | |
|
||
language: php | ||
|
||
sudo: false | ||
dist: trusty | ||
sudo: required | ||
|
||
php: | ||
- 5.5 | ||
- 5.6 | ||
- 7.0 | ||
- 7.1 | ||
- 7.2 | ||
|
||
services: | ||
- memcached | ||
- redis | ||
- redis-server | ||
- mongodb | ||
- mysql | ||
- beanstalkd | ||
|
||
git: | ||
depth: 1 | ||
|
||
cache: | ||
apt: true | ||
ccache: true | ||
timeout: 691200 | ||
timeout: 604800 | ||
directories: | ||
- vendor | ||
- $HOME/.ccache | ||
- $HOME/.composer/cache | ||
- $HOME/pear | ||
- $HOME/cphalcon | ||
- $HOME/ext | ||
- $HOME/.local/lib | ||
|
||
env: | ||
global: | ||
- ZEND_DONT_UNLOAD_MODULES=1 | ||
- CC="ccache gcc" | ||
- PATH="$PATH:~/bin" | ||
- PHALCON_VERSION="v3.2.1" | ||
- PHALCON_VERSION=v3.3.1 | ||
|
||
addons: | ||
apt: | ||
packages: | ||
- beanstalkd | ||
hosts: | ||
- db | ||
- incubator.local | ||
|
||
before_install: | ||
- export PHP_MAJOR="$(echo $TRAVIS_PHP_VERSION | cut -d '.' -f 1)" | ||
- export PHP_EXTENSION_DIR=$(php-config --extension-dir) | ||
- phpenv config-rm xdebug.ini || true | ||
- if [ -n "$GH_TOKEN" ]; then composer config github-oauth.github.com $GH_TOKEN; fi; | ||
- export PHP_MAJOR="$(`phpenv which php` -r 'echo phpversion();' | cut -d '.' -f 1)" | ||
- bash tests/_ci/pear_setup.sh | ||
- bash tests/_ci/install_prereqs_$PHP_MAJOR.sh | ||
- if [ ! -z "${GH_TOKEN}" ]; then composer config github-oauth.github.com ${GH_TOKEN}; echo "Configured Github token"; fi; | ||
- if [ ! -f "$HOME/cphalcon/$PHALCON_VERSION/tests/_ci/phalcon.ini" ]; then mkdir -p $HOME/cphalcon/$PHALCON_VERSION && git clone -q --depth=1 https://github.com/phalcon/cphalcon.git $HOME/cphalcon/$PHALCON_VERSION >/dev/null 2>&1; fi; | ||
|
||
install: | ||
# See https://github.com/aerospike/aerospike-client-php/issues/127 | ||
- '[[ "$PHP_MAJOR" == "5" ]] || bash ${TRAVIS_BUILD_DIR}/tests/_ci/install_aerospike.sh' | ||
- if [ ! -f $HOME/ext/$PHP_VERSION/$PHALCON_VERSION/phalcon.so ]; then cd $HOME/cphalcon/$PHALCON_VERSION/build && bash ./install --phpize $(phpenv which phpize) --php-config $(phpenv which php-config) && mkdir -p $HOME/ext/$PHP_VERSION/$PHALCON_VERSION && cp $PHP_EXTENSION_DIR/phalcon.so $HOME/ext/$PHP_VERSION/$PHALCON_VERSION/phalcon.so; fi; | ||
- if [ -f $HOME/ext/$PHP_VERSION/$PHALCON_VERSION/phalcon.so ]; then cp $HOME/ext/$PHP_VERSION/$PHALCON_VERSION/phalcon.so $PHP_EXTENSION_DIR/phalcon.so; fi; | ||
- phpenv config-add $HOME/cphalcon/$PHALCON_VERSION/tests/_ci/phalcon.ini | ||
- phpenv config-add ${TRAVIS_BUILD_DIR}/tests/_ci/redis.ini | ||
- bash $TRAVIS_BUILD_DIR/tests/_ci/install_phalcon.sh | ||
- cd $TRAVIS_BUILD_DIR | ||
- $(phpenv which php) --ri phalcon | ||
- travis_retry composer install --prefer-dist --no-interaction --no-ansi --no-progress --optimize-autoloader --dev --no-suggest | ||
- phpenv config-add $TRAVIS_BUILD_DIR/tests/_ci/ci.ini | ||
- ls -al `$(phpenv which php-config) --extension-dir` | ||
- $(phpenv which php) -v | ||
- $(phpenv which php) -m | ||
|
||
before_script: | ||
# Create database and user | ||
- echo 'CREATE DATABASE incubator CHARSET=utf8 COLLATE=utf8_unicode_ci' | mysql -u root | ||
- echo "CREATE USER 'incubator'@'%' IDENTIFIED BY 'secret'" | mysql -u root | ||
- echo "GRANT ALL PRIVILEGES ON incubator.* TO 'incubator'@'%' WITH GRANT OPTION" | mysql -u root | ||
- cat ${TRAVIS_BUILD_DIR}/tests/_data/dump.sql | mysql -u root incubator | ||
# See https://github.com/aerospike/aerospike-client-php/issues/127 | ||
- '[[ "${PHP_MAJOR:0:1}" == "5" ]] || bash ${TRAVIS_BUILD_DIR}/tests/_ci/install_aserver.sh' | ||
|
||
script: | ||
- vendor/bin/phpcs | ||
- vendor/bin/codecept build | ||
- vendor/bin/codecept run -v tests/unit | ||
- '[[ "$PHP_MAJOR" == "5" ]] || vendor/bin/codecept run -v tests/aerospike' | ||
- '[[ "$PHP_MAJOR" == "7" ]] || vendor/bin/codecept run -v tests/unit5x' | ||
|
||
after_failure: | ||
- for file in `ls ./tests/_output`; do [ -f ./tests/_output/$file ] && cat ./tests/_output/$file; done; | ||
|
||
notifications: | ||
email: | ||
recipients: | ||
- [email protected] | ||
on_success: change | ||
on_failure: always | ||
|
||
addons: | ||
apt: | ||
packages: | ||
- re2c | ||
- beanstalkd | ||
- python-bcrypt | ||
- build-essential | ||
- autoconf | ||
- libssl-dev | ||
- libyaml-dev | ||
- liblua5.1-dev | ||
- mysql-server-5.6 | ||
- mysql-server-core-5.6 | ||
- mysql-client-5.6 | ||
hosts: | ||
- db | ||
- incubator.local | ||
on_success: never | ||
on_failure: never |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
<?php | ||
/* | ||
+------------------------------------------------------------------------+ | ||
| Phalcon Framework | | ||
+------------------------------------------------------------------------+ | ||
| Copyright (c) 2011-2016 Phalcon Team (https://www.phalconphp.com) | | ||
+------------------------------------------------------------------------+ | ||
| This source file is subject to the New BSD License that is bundled | | ||
| with this package in the file LICENSE.txt. | | ||
| | | ||
| If you did not receive a copy of the license and are unable to | | ||
| obtain it through the world-wide-web, please send an email | | ||
| to [email protected] so we can send you a copy immediately. | | ||
+------------------------------------------------------------------------+ | ||
| Authors: Phoenix Osiris <[email protected]> | | ||
+------------------------------------------------------------------------+ | ||
*/ | ||
|
||
namespace Phalcon\Test\Codeception; | ||
|
||
use Phalcon\Test\Traits\FunctionalTestCase as FunctionalTestCaseTrait; | ||
|
||
class FunctionalTestCase extends ModelTestCase | ||
{ | ||
use FunctionalTestCaseTrait; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
<?php | ||
/* | ||
+------------------------------------------------------------------------+ | ||
| Phalcon Framework | | ||
+------------------------------------------------------------------------+ | ||
| Copyright (c) 2011-2016 Phalcon Team (https://www.phalconphp.com) | | ||
+------------------------------------------------------------------------+ | ||
| This source file is subject to the New BSD License that is bundled | | ||
| with this package in the file LICENSE.txt. | | ||
| | | ||
| If you did not receive a copy of the license and are unable to | | ||
| obtain it through the world-wide-web, please send an email | | ||
| to [email protected] so we can send you a copy immediately. | | ||
+------------------------------------------------------------------------+ | ||
| Authors: Phoenix Osiris <[email protected]> | | ||
+------------------------------------------------------------------------+ | ||
*/ | ||
|
||
namespace Phalcon\Test\Codeception; | ||
|
||
use Phalcon\Test\Traits\ModelTestCase as ModelTestCaseTrait; | ||
|
||
class ModelTestCase extends UnitTestCase | ||
{ | ||
use ModelTestCaseTrait; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
<?php | ||
/* | ||
+------------------------------------------------------------------------+ | ||
| Phalcon Framework | | ||
+------------------------------------------------------------------------+ | ||
| Copyright (c) 2011-2016 Phalcon Team (https://www.phalconphp.com) | | ||
+------------------------------------------------------------------------+ | ||
| This source file is subject to the New BSD License that is bundled | | ||
| with this package in the file LICENSE.txt. | | ||
| | | ||
| If you did not receive a copy of the license and are unable to | | ||
| obtain it through the world-wide-web, please send an email | | ||
| to [email protected] so we can send you a copy immediately. | | ||
+------------------------------------------------------------------------+ | ||
| Authors: Phoenix Osiris <[email protected]> | | ||
+------------------------------------------------------------------------+ | ||
*/ | ||
|
||
namespace Phalcon\Test\Codeception; | ||
|
||
use Codeception\Test\Unit; | ||
|
||
use Phalcon\Test\Traits\UnitTestCase as UnitTestCaseTrait; | ||
use UnitTester; | ||
|
||
class UnitTestCase extends Unit | ||
{ | ||
use UnitTestCaseTrait; | ||
|
||
|
||
/** | ||
* UnitTester Object | ||
* @var UnitTester | ||
*/ | ||
protected $tester; | ||
|
||
/** | ||
* Standard Setup Method For PHPUnit. Calling setUpPhalcon Here to Maintain Codeception's _before Without a call | ||
* to parent::_before | ||
*/ | ||
protected function setUp() | ||
{ | ||
$this->setUpPhalcon(); | ||
parent::setUp(); | ||
} | ||
|
||
/** | ||
* Standard Tear Down Method For PHPUnit. Calling tearDownPhalcon Here to Maintain Codeception's _after | ||
* Without a call to parent::_before | ||
*/ | ||
protected function tearDown() | ||
{ | ||
$this->tearDownPhalcon(); | ||
parent::tearDown(); | ||
} | ||
} |
Oops, something went wrong.