CakePHP 2.4 tests failing with PHP Error Edited

Last week my builds started to fail, and I can't figure out the problem. I've spent a few days on it.

I have pulled the same docker image I am using in my pipeline and ran all the same commands in the pipeline and it works.

I have listed the contents of the directories and CollectionComponent.php does exist.

Pipeline:

image:
name: gcr.io/project-name/image:latest
username: _json_key
password: '$JSON_KEY'
email: pipelines@bitbucket.com

pipelines:
default:
- step:
caches:
- composer
script:
- composer install
- chmod +x ./scripts/pipeline/* ./application/app/Console/cake
- make database
- make test
services:
- database

definitions:
services:
database:
image: mysql:5.5.43
environment:
MYSQL_ROOT_PASSWORD: 'root'
MYSQL_DATABASE: 'password'

 

`compose install`:

composer install

Do not run Composer as root/super user! See https://getcomposer.org/root for details

Loading composer repositories with package information

Installing dependencies (including require-dev) from lock file

Package operations: 70 installs, 0 updates, 0 removals

- Installing composer/installers (v1.4.0): Downloading (connecting...)Downloading (0%) Downloading (15%)Downloading (25%)Downloading (40%)Downloading (55%)Downloading (70%)Downloading (75%)Downloading (85%)Downloading (90%)Downloading (100%)

<snip>

paragonie/random_compat suggests installing ext-libsodium (Provides a modern crypto API that can be used to generate random bytes.)

illuminate/support suggests installing illuminate/filesystem (Required to use the composer class (5.2.*).)

illuminate/support suggests installing jeremeamia/superclosure (Required to be able to serialize closures (~2.2).)

illuminate/support suggests installing symfony/polyfill-php56 (Required to use the hash_equals function on PHP 5.5 (~1.0).)

illuminate/support suggests installing symfony/var-dumper (Improves the dd function (2.8.*|3.0.*).)

illuminate/database suggests installing doctrine/dbal (Required to rename columns and drop SQLite columns (~2.4).)

illuminate/database suggests installing illuminate/events (Required to use the observers with Eloquent (5.2.*).)

illuminate/database suggests installing illuminate/filesystem (Required to use the migrations (5.2.*).)

illuminate/database suggests installing illuminate/pagination (Required to paginate the result set (5.2.*).)

illuminate/console suggests installing mtdowling/cron-expression (Required to use scheduling component (~1.0).)

illuminate/queue suggests installing aws/aws-sdk-php (Required to use the SQS queue driver (~3.0).)

predis/predis suggests installing ext-phpiredis (Allows faster serialization and deserialization of the Redis protocol)

sentry/sentry suggests installing immobiliare/sentry-php (Fork that fixes support for PHP 5.2)

sentry/sentry suggests installing monolog/monolog (Automatically capture Monolog events as breadcrumbs)

behat/mink suggests installing behat/mink-zombie-driver (fast and JS-enabled headless driver for any app (requires node.js))

symfony/event-dispatcher suggests installing symfony/http-kernel ()

symfony/dependency-injection suggests installing symfony/expression-language (For using expressions in service container configuration)

symfony/dependency-injection suggests installing symfony/proxy-manager-bridge (Generate service proxies to lazy load them)

symfony/class-loader suggests installing symfony/polyfill-apcu (For using ApcClassLoader on HHVM)

behat/behat suggests installing behat/symfony2-extension (for integration with Symfony2 web framework)

behat/behat suggests installing behat/yii-extension (for integration with Yii web framework)

phpunit/php-code-coverage suggests installing ext-xdebug (>=2.0.5)

phpunit/phpunit suggests installing phpunit/php-invoker (~1.1)

Generating autoload files

 

make test:

#!/bin/bash -e

# Run Unit Tests
${BITBUCKET_CLONE_DIR}/application/app/Console/cake test app AllNonIntegrationTests --stderr --log-junit ${BITBUCKET_CLONE_DIR}/junit.xml

 

Error:

bitbucket_php_error.PNG

1 answer

1 accepted

Looks like it's fixed now. I have to assume it was BitBuckets environment since I had put this project on hold (no code changes, nothing in the last 11 days) and now I just re-ran a build that had previously failed and the error is gone.

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Posted Jun 12, 2018 in Bitbucket

Do you use any Atlassian products for your personal projects?

After spinning my wheels trying to get organized enough to write a book for National Novel Writing Month (NaNoWriMo) I took my affinity for Atlassian products from my work life and decided to tr...

28,032 views 26 12
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you