So, I followed this tutorial:
http://framework.zend.com/manual/2.0/en/user-guide/routing-and-controllers.html
I am at the point where I should run phpunit - I run the command phpunit module/Album/src/Album/Controller/AlbumControllerTest.php
and I have a problem:
PHP Fatal error: Class 'Zend\Mvc\Application' not found in /home/...rest of the folders here.../AlbumControllerTest.php on line 71
line 71 in AlbumControllerTest.php:
$bootstrap = \Zend\Mvc\Application::init(include 'config/application.config.php');
When I look under Zend / Mvc / i, I see a file called Application, so I assume this is not a problem.
config / application.config.php looks like this:
<?php // config/application.config.php: return array( 'modules' => array( 'Application', 'Album', // <-- Add this line ), 'module_listener_options' => array( 'config_glob_paths' => array( 'config/autoload/{,*.}{global,local}.php', ), 'module_paths' => array( './module', './vendor', ), ), ); ?>
according to the textbook - I believe. Does anyone know how to solve this ?!
source share