ZF-2604: Unittests hang
Description
The unittests for Zend_Cache_PageFrontendTest hang. They are running forever until all memory is exhausted.
Zend_Cache_CoreTest
.....................................
Zend_Cache_FileBackendTest
..............................
Zend_Cache_OutputFrontendTest
...
Zend_Cache_FunctionFrontendTest
.........
Zend_Cache_ClassFrontendTest
...........
Zend_Cache_FileFrontendTest
...........
Zend_Cache_PageFrontendTest
.........
Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate
984 bytes) in C:\Voxtronic\3rdParty\Zend Framework\library\Zend\Gdata\App\Exten
sion\Person.php on line 244
I am using the latest trunk with PHP5.2.5. What I don't understand is, that Zend_Gdata throws the error but the output says Zend_Cache is the problem...
When running the tests independently with AllTests it runs through but generates an error.
C:\Voxtronic\3rdParty\Zend Framework\tests>phpunit --verbose Zend_Cache_AllTests
PHPUnit 3.2.7 by Sebastian Bergmann.
Zend Framework - Zend_Cache
Zend_Cache_FactoryTest
..
Warning: Zend_Loader::include_once(Zend\Cache\Frontend\Badfrontend.php): failed
to open stream: No such file or directory in C:\Voxtronic\3rdParty\Zend Framewor
k\library\Zend\Loader.php on line 83
Call Stack:
0.0019 178344 1. {main}() C:\Voxtronic\3rdParty\php\PEAR\PHPUnit\TextU
I\Command.php:0
0.7876 7735696 2. PHPUnit_TextUI_Command::main() C:\Voxtronic\3rdParty\
php\PEAR\PHPUnit\TextUI\Command.php:528
15.6171 10266360 3. PHPUnit_TextUI_TestRunner->doRun() C:\Voxtronic\3rdPa
rty\php\PEAR\PHPUnit\TextUI\Command.php:112
15.6175 10272920 4. PHPUnit_Framework_TestSuite->run() C:\Voxtronic\3rdPa
rty\php\PEAR\PHPUnit\TextUI\TestRunner.php:298
15.6191 10275264 5. PHPUnit_Framework_TestSuite->run() C:\Voxtronic\3rdPa
rty\php\PEAR\PHPUnit\Framework\TestSuite.php:633
15.6287 10366992 6. PHPUnit_Framework_TestSuite->runTest() C:\Voxtronic\3
rdParty\php\PEAR\PHPUnit\Framework\TestSuite.php:650
15.6288 10366992 7. PHPUnit_Framework_TestCase->run() C:\Voxtronic\3rdPar
ty\php\PEAR\PHPUnit\Framework\TestSuite.php:670
15.6288 10367168 8. PHPUnit_Framework_TestResult->run() C:\Voxtronic\3rdP
arty\php\PEAR\PHPUnit\Framework\TestCase.php:351
15.6289 10369288 9. PHPUnit_Framework_TestCase->runBare() C:\Voxtronic\3r
dParty\php\PEAR\PHPUnit\Framework\TestResult.php:597
15.6293 10402896 10. PHPUnit_Framework_TestCase->runTest() C:\Voxtronic\3r
dParty\php\PEAR\PHPUnit\Framework\TestCase.php:373
15.6293 10404104 11. ReflectionMethod->invoke() C:\Voxtronic\3rdParty\php\
PEAR\PHPUnit\Framework\TestCase.php:445
15.6293 10404104 12. Zend_Cache_FactoryTest->testBadFrontend() C:\Voxtroni
c\3rdParty\Zend Framework\tests\Zend\Cache\FactoryTest.php:0
15.6293 10404104 13. Zend_Cache::factory() C:\Voxtronic\3rdParty\Zend Fram
ework\tests\Zend\Cache\FactoryTest.php:53
15.6308 10452896 14. Zend_Loader::loadClass() C:\Voxtronic\3rdParty\Zend F
ramework\library\Zend\Cache.php:95
Warning: Zend_Loader::include_once(): Failed opening 'Zend\Cache\Frontend\Badfro
ntend.php' for inclusion (include_path='C:\Voxtronic\3rdParty\Zend Framework\lib
rary;C:\Voxtronic\3rdParty\Zend Framework\tests;.;C:\Voxtronic\3rdParty\php\pear
\;C:\Voxtronic\3rdParty\Zend Framework\incubator\library;C:\Voxtronic\3rdParty\Z
end Framework\library;C:\Voxtronic\voxct_v3\web\library') in C:\Voxtronic\3rdPar
ty\Zend Framework\library\Zend\Loader.php on line 83
Call Stack:
0.0019 178344 1. {main}() C:\Voxtronic\3rdParty\php\PEAR\PHPUnit\TextU
I\Command.php:0
0.7876 7735696 2. PHPUnit_TextUI_Command::main() C:\Voxtronic\3rdParty\
php\PEAR\PHPUnit\TextUI\Command.php:528
15.6171 10266360 3. PHPUnit_TextUI_TestRunner->doRun() C:\Voxtronic\3rdPa
rty\php\PEAR\PHPUnit\TextUI\Command.php:112
15.6175 10272920 4. PHPUnit_Framework_TestSuite->run() C:\Voxtronic\3rdPa
rty\php\PEAR\PHPUnit\TextUI\TestRunner.php:298
15.6191 10275264 5. PHPUnit_Framework_TestSuite->run() C:\Voxtronic\3rdPa
rty\php\PEAR\PHPUnit\Framework\TestSuite.php:633
15.6287 10366992 6. PHPUnit_Framework_TestSuite->runTest() C:\Voxtronic\3
rdParty\php\PEAR\PHPUnit\Framework\TestSuite.php:650
15.6288 10366992 7. PHPUnit_Framework_TestCase->run() C:\Voxtronic\3rdPar
ty\php\PEAR\PHPUnit\Framework\TestSuite.php:670
15.6288 10367168 8. PHPUnit_Framework_TestResult->run() C:\Voxtronic\3rdP
arty\php\PEAR\PHPUnit\Framework\TestCase.php:351
15.6289 10369288 9. PHPUnit_Framework_TestCase->runBare() C:\Voxtronic\3r
dParty\php\PEAR\PHPUnit\Framework\TestResult.php:597
15.6293 10402896 10. PHPUnit_Framework_TestCase->runTest() C:\Voxtronic\3r
dParty\php\PEAR\PHPUnit\Framework\TestCase.php:373
15.6293 10404104 11. ReflectionMethod->invoke() C:\Voxtronic\3rdParty\php\
PEAR\PHPUnit\Framework\TestCase.php:445
15.6293 10404104 12. Zend_Cache_FactoryTest->testBadFrontend() C:\Voxtroni
c\3rdParty\Zend Framework\tests\Zend\Cache\FactoryTest.php:0
15.6293 10404104 13. Zend_Cache::factory() C:\Voxtronic\3rdParty\Zend Fram
ework\tests\Zend\Cache\FactoryTest.php:53
15.6308 10452896 14. Zend_Loader::loadClass() C:\Voxtronic\3rdParty\Zend F
ramework\library\Zend\Cache.php:95
.
Warning: Zend_Loader::include_once(Zend\Cache\Backend\Badbackend.php): failed to
open stream: No such file or directory in C:\Voxtronic\3rdParty\Zend Framework\
library\Zend\Loader.php on line 83
Call Stack:
0.0019 178344 1. {main}() C:\Voxtronic\3rdParty\php\PEAR\PHPUnit\TextU
I\Command.php:0
0.7876 7735696 2. PHPUnit_TextUI_Command::main() C:\Voxtronic\3rdParty\
php\PEAR\PHPUnit\TextUI\Command.php:528
15.6171 10266360 3. PHPUnit_TextUI_TestRunner->doRun() C:\Voxtronic\3rdPa
rty\php\PEAR\PHPUnit\TextUI\Command.php:112
15.6175 10272920 4. PHPUnit_Framework_TestSuite->run() C:\Voxtronic\3rdPa
rty\php\PEAR\PHPUnit\TextUI\TestRunner.php:298
15.6191 10275264 5. PHPUnit_Framework_TestSuite->run() C:\Voxtronic\3rdPa
rty\php\PEAR\PHPUnit\Framework\TestSuite.php:633
15.6386 10419080 6. PHPUnit_Framework_TestSuite->runTest() C:\Voxtronic\3
rdParty\php\PEAR\PHPUnit\Framework\TestSuite.php:650
15.6386 10419080 7. PHPUnit_Framework_TestCase->run() C:\Voxtronic\3rdPar
ty\php\PEAR\PHPUnit\Framework\TestSuite.php:670
15.6386 10419256 8. PHPUnit_Framework_TestResult->run() C:\Voxtronic\3rdP
arty\php\PEAR\PHPUnit\Framework\TestCase.php:351
15.6387 10421376 9. PHPUnit_Framework_TestCase->runBare() C:\Voxtronic\3r
dParty\php\PEAR\PHPUnit\Framework\TestResult.php:597
15.6392 10454976 10. PHPUnit_Framework_TestCase->runTest() C:\Voxtronic\3r
dParty\php\PEAR\PHPUnit\Framework\TestCase.php:373
15.6392 10456184 11. ReflectionMethod->invoke() C:\Voxtronic\3rdParty\php\
PEAR\PHPUnit\Framework\TestCase.php:445
15.6392 10456184 12. Zend_Cache_FactoryTest->testBadBackend() C:\Voxtronic
\3rdParty\Zend Framework\tests\Zend\Cache\FactoryTest.php:0
15.6392 10456184 13. Zend_Cache::factory() C:\Voxtronic\3rdParty\Zend Fram
ework\tests\Zend\Cache\FactoryTest.php:63
15.6407 10457320 14. Zend_Loader::loadClass() C:\Voxtronic\3rdParty\Zend F
ramework\library\Zend\Cache.php:110
Warning: Zend_Loader::include_once(): Failed opening 'Zend\Cache\Backend\Badback
end.php' for inclusion (include_path='C:\Voxtronic\3rdParty\Zend Framework\libra
ry;C:\Voxtronic\3rdParty\Zend Framework\tests;.;C:\Voxtronic\3rdParty\php\pear\;
C:\Voxtronic\3rdParty\Zend Framework\incubator\library;C:\Voxtronic\3rdParty\Zen
d Framework\library;C:\Voxtronic\voxct_v3\web\library') in C:\Voxtronic\3rdParty
\Zend Framework\library\Zend\Loader.php on line 83
Call Stack:
0.0019 178344 1. {main}() C:\Voxtronic\3rdParty\php\PEAR\PHPUnit\TextU
I\Command.php:0
0.7876 7735696 2. PHPUnit_TextUI_Command::main() C:\Voxtronic\3rdParty\
php\PEAR\PHPUnit\TextUI\Command.php:528
15.6171 10266360 3. PHPUnit_TextUI_TestRunner->doRun() C:\Voxtronic\3rdPa
rty\php\PEAR\PHPUnit\TextUI\Command.php:112
15.6175 10272920 4. PHPUnit_Framework_TestSuite->run() C:\Voxtronic\3rdPa
rty\php\PEAR\PHPUnit\TextUI\TestRunner.php:298
15.6191 10275264 5. PHPUnit_Framework_TestSuite->run() C:\Voxtronic\3rdPa
rty\php\PEAR\PHPUnit\Framework\TestSuite.php:633
15.6386 10419080 6. PHPUnit_Framework_TestSuite->runTest() C:\Voxtronic\3
rdParty\php\PEAR\PHPUnit\Framework\TestSuite.php:650
15.6386 10419080 7. PHPUnit_Framework_TestCase->run() C:\Voxtronic\3rdPar
ty\php\PEAR\PHPUnit\Framework\TestSuite.php:670
15.6386 10419256 8. PHPUnit_Framework_TestResult->run() C:\Voxtronic\3rdP
arty\php\PEAR\PHPUnit\Framework\TestCase.php:351
15.6387 10421376 9. PHPUnit_Framework_TestCase->runBare() C:\Voxtronic\3r
dParty\php\PEAR\PHPUnit\Framework\TestResult.php:597
15.6392 10454976 10. PHPUnit_Framework_TestCase->runTest() C:\Voxtronic\3r
dParty\php\PEAR\PHPUnit\Framework\TestCase.php:373
15.6392 10456184 11. ReflectionMethod->invoke() C:\Voxtronic\3rdParty\php\
PEAR\PHPUnit\Framework\TestCase.php:445
15.6392 10456184 12. Zend_Cache_FactoryTest->testBadBackend() C:\Voxtronic
\3rdParty\Zend Framework\tests\Zend\Cache\FactoryTest.php:0
15.6392 10456184 13. Zend_Cache::factory() C:\Voxtronic\3rdParty\Zend Fram
ework\tests\Zend\Cache\FactoryTest.php:63
15.6407 10457320 14. Zend_Loader::loadClass() C:\Voxtronic\3rdParty\Zend F
ramework\library\Zend\Cache.php:110
.
Zend_Cache_CoreTest
.....................................
Zend_Cache_FileBackendTest
..............................
Zend_Cache_OutputFrontendTest
...
Zend_Cache_FunctionFrontendTest
.........
Zend_Cache_ClassFrontendTest
...........
Zend_Cache_FileFrontendTest
...........
Zend_Cache_PageFrontendTest
.........E.E
SSSS
Time: 3 seconds
There were 2 errors:
1) testStartEndCorrectCall1(Zend_Cache_PageFrontendTest)
unserialize(): Error at offset 0 of 3 bytes
C:\Voxtronic\3rdParty\Zend Framework\library\Zend\Cache\Core.php:224
C:\Voxtronic\3rdParty\Zend Framework\library\Zend\Cache\Frontend\Page.php:205
C:\Voxtronic\3rdParty\Zend Framework\tests\Zend\Cache\PageFrontendTest.php:140
2) testStartEndCorrectCallWithDebug(Zend_Cache_PageFrontendTest)
unserialize(): Error at offset 0 of 3 bytes
C:\Voxtronic\3rdParty\Zend Framework\library\Zend\Cache\Core.php:224
C:\Voxtronic\3rdParty\Zend Framework\library\Zend\Cache\Frontend\Page.php:205
C:\Voxtronic\3rdParty\Zend Framework\tests\Zend\Cache\PageFrontendTest.php:169
There were 4 skipped tests:
1) (Zend_Cache_SqliteBackendTest_SkipTests)
Tests are not enabled in TestConfiguration.php
2) (Zend_Cache_ApcBackendTest_SkipTests)
Tests are not enabled in TestConfiguration.php
3) (Zend_Cache_MemcachedBackendTest_SkipTests)
Tests are not enabled in TestConfiguration.php
4) (Zend_Cache_ZendPlatformBackendTest_SkipTests)
Tests are not enabled in TestConfiguration.php
FAILURES!
Tests: 121, Errors: 2, Skipped: 4.
Hope the data helps to track down the problem.
Comments
Posted by Fabien MARTY (fab) on 2008-02-17T14:15:12.000+0000
Zend_Cache issues are fixed in SVN trunk (thanks)
Posted by Wil Sinclair (wil) on 2008-12-17T13:19:39.000+0000
Bookkeeping. Closing and assigning all old unassigned issues. The only unassigned issues should be new and unreviewed.