yiisoft/yii2-app-basic — pull request #1 by mcd-php (2013-09-04 15:01:26+00:00)
Title: FIXED: Codeception crash right out of the cloning vat

N.B. Please apply the fix to another projects then applicable, and to framework's application generator

Shell script to test the tests:

#!/bin/sh

# Destructive, uncomment if sure
# rm -rf yii2-app-basic
git clone https://github.com/yiisoft/yii2-app-basic.git
cd yii2-app-basic
php -r "eval('?>'.file_get_contents('https://getcomposer.org/installer'));"
php composer.phar update
wget https://github.com/Codeception/Codeception/raw/master/package/codecept.phar
sudo php -S localhost:80 -t web &
php codecept.phar build
php codecept.phar run

Before fix, it crashes with error:

yii\base\InvalidConfigException: Object configuration must be an array containing a "class" element.

#1 phar:///codecept.phar/src/Codeception/Util/Connector/Yii2.php(65)
#2 phar:///codecept.phar/vendor/symfony/browser-kit/Symfony/Component/BrowserKit/Client.php(324)
#3 phar:///codecept.phar/src/Codeception/Util/Framework.php(61)
#5 phar:///codecept.phar/src/Codeception/Step.php(126)
#6 phar:///codecept.phar/src/Codeception/TestCase.php(31)
#7 phar:///codecept.phar/src/Codeception/Scenario.php(87)
#8 /tests/functional/TestGuy.php(491)
#9 /tests/functional/AboutCept.php(4)
#10 phar:///codecept.phar/src/Codeception/TestCase/Cept.php(77)
#12 phar:///codecept.phar/vendor/phpunit/phpunit/PHPUnit/Framework/TestCase.php(983)
#13 phar:///codecept.phar/vendor/phpunit/phpunit/PHPUnit/Framework/TestCase.php(838)
#14 phar:///codecept.phar/vendor/phpunit/phpunit/PHPUnit/Framework/TestResult.php(648)
#15 phar:///codecept.phar/vendor/phpunit/phpunit/PHPUnit/Framework/TestCase.php(783)
#16 phar:///codecept.phar/vendor/phpunit/phpunit/PHPUnit/Framework/TestSuite.php(775)
#17 phar:///codecept.phar/vendor/phpunit/phpunit/PHPUnit/Framework/TestSuite.php(745)
#18 phar:///codecept.phar/src/Codeception/PHPUnit/Runner.php(58)
#19 phar:///codecept.phar/src/Codeception/SuiteManager.php(142)
#20 phar:///codecept.phar/src/Codeception/Codecept.php(130)
#21 phar:///codecept.phar/src/Codeception/Command/Run.php(114)
#22 phar:///codecept.phar/src/Codeception/Command/Run.php(82)
#23 phar:///codecept.phar/vendor/symfony/console/Symfony/Component/Console/Command/Command.php(244)
#24 phar:///codecept.phar/vendor/symfony/console/Symfony/Component/Console/Application.php(897)
#25 phar:///codecept.phar/vendor/symfony/console/Symfony/Component/Console/Application.php(191)
#26 phar:///codecept.phar/vendor/symfony/console/Symfony/Component/Console/Application.php(121)
#27 phar:///codecept.phar/codecept(29)
#28 /codecept.phar(7)

After fix, it passes.