ZF-10708: Cannot redeclare class


Unit tests of ZF2 fail with the following information:

E_COMPILE_ERROR: Cannot redeclare class ZendTest\File\Transfer\Adapter\HttpTest
#0 /home/rtuin/projects/github/zf2/tests/Zend/File/Transfer/Adapter/HTTPTest.php(283)
PHP Fatal error:  Cannot redeclare class ZendTest\File\Transfer\Adapter\HttpTest in /home/rtuin/projects/github/zf2/tests/Zend/File/Transfer/Adapter/HTTPTest.php on line 283


It turns out there are 2 files containing the same class: HTTPTest.php and HttpTest.php

Working on a fix now.

Have you been tracking for some time? and if so, are you using a case insensitive file system (such as Mac, Windows)? We've noticed oddities like that before when we've renamed files to switch case.

Currently, master only shows a Zend/File/Transfer/Adapter/Http.php file, which leads me to believe this is the case for you. As such, I recommend either doing a new clone, or switching to a case sensitive drive partition.

Please note this issue is related to a Unit Test, rather than the library part of the framework. The exact path both of the files are in are in the "/tests/Zend/File/Transfer/Adapter/" folder.

I am running Ubuntu linux, on a case sensitive partition.

I think i have valid arguments for reopening this issue.

Missed that it was in "tests"; fixed in current master.