We have moved our forum to GitHub Discussions. For questions about Phalcon v3/v4/v5 you can visit here and for Phalcon v6 here.

Installing Phalcon extension for testing with Travis

Related to PR: https://github.com/phalcon/phalcon-devtools/pull/1041

In the process of adding a new command to devtools I implemented codeception for testing but I am having a hard time getting phalcon installed from apt-get in my build matrix.

The build matrix is:

    - php: 5.5
      install: sudo apt-get install php5-phalcon
    - php: 5.6
      install: sudo apt-get install php5-phalcon
    - php: 7.0
      env: ZEND_BACKEND="--backend=ZendEngine3"
      install: sudo apt-get install php7.0-phalcon

PHP 5.5 and 5.6

For PHP 5.5 and 5.6 the build fails because the test running cannot find the classes from the Phalcon extension:


ServeTest: Default values with no parametersPHP Fatal error:  Class 'Phalcon\Events\Manager' not found in /home/travis/build/phalcon/phalcon-devtools/tests/unit/ServeTest.php on line 31

In this case I assume that the extension is not being registered by apt-get in the right ini file possibly.


For PHP 7.0 the build cannot use the donload listed for PHP7 on the Phalcon download page.


The following packages have unmet dependencies:
 php7.0-phalcon : Depends: phpapi-20151012 but it is not installable
E: Unable to correct problems, you have held broken packages.
The command "sudo apt-get install php7.0-phalcon" failed and exited with 100 during .

In this case Phalcon for PHP7 is missing a pacakge dep from 2015 or I need to install more dependencies.

Looking for some help.