if i run ‘phpunit AllTests.php’ in tests directory (system/application/tests) it works fine. but the time when i run’phpunit ModelsAllTests.php’ inside the subdirectory of test i.e(system/application/tests/models) it shows some error. inmy case it is
PHP Warning: require(/opt/lampp/htdocs/calculator/system/application/libraries/fooStack/fooBase/../../../../../../application/libraries/fooStack/fooBase/Common.php): failed to open stream: No such file or directory in /opt/lampp/htdocs/calculator/system/application/libraries/fooStack/fooBase/CodeIgniter.php on line 39
PHP Fatal error: require(): Failed opening required ‘/opt/lampp/htdocs/calculator/system/application/libraries/fooStack/fooBase/../../../../../../application/libraries/fooStack/fooBase/Common.php’ (include_path=’.:/opt/lampp/lib/php/PEAR:/root/PEAR’) in /opt/lampp/htdocs/calculator/system/application/libraries/fooStack/fooBase/CodeIgniter.php on line 39
what r the changes i need to do to overcome this?
i also want to know where should i write the test cases for a controller and a model respectively.
Finally I got it working. this problem was due to the wrong path setting in the
application/libraries/fooStack/fooBase/index.php for $system_folder at line# 26 and for $application_folder at line # 43.
I am using fooStack v0.17 - for CI 1.7.2. in my case
$system_folder = “../../../../../system”; and
$application_folder = “application”;
This may save some hours for somebody who gets this problem.
sidhartha