[TYPO3-dev] PHPUnit cache?

François Suter fsu-lists at cobweb.ch
Wed Nov 27 17:22:08 CET 2013


Hi Helmut,

> /Users/fsuter/Sites/foo/typo3conf/ext/foo/Tests/Calculation/CalculationTest.php
>
> (not in Tests/Unit/ like AnnualizedPerformanceTest.php)

That did it.

I was also kind of surprised to put the tests in the "Unit" subfolder, 
but I actually followed the structure created by the Extension Builder 
for default test classes for domain models.

But it had really weird effects all around. On top of the problem 
discussed here, I found out that if I added "Unit/" in the namespace, i.e.

namespace Cobweb\Foo\Tests\Unit\Calculation;

PphStorm would not resolve the name of the base class.

Maybe part of the mess is due to the namespace declared in the domain 
model test classes, which is just

namespace Cobweb\Foo\Tests;

Again, this seems to be the default output by the Extension Builder. I 
don't know if it's a good idea, nor how namespaces and file paths are 
actually resolved in such cases. The sure is that they don't match, but 
that does not seem to bother phpunit.

Anyway moving the test classes around worked, thanks for the suggestion. 
There's still some black magic going on, but I'm going to ignore it for 
now, as it is not critical.

Cheers

-- 

Francois Suter

Work: Cobweb Development Sarl - http://www.cobweb.ch

TYPO3: Help the project! - http://typo3.org/contribute/

Appreciate my work? Support me -
http://www.monpetitcoin.com/en/francois/support-me/




More information about the TYPO3-dev mailing list