I wanted to add a blog to my cakephp 2.6.13 installation and named the table Post. After I was done with everything I ran the tests and discovered, that they fail.
PHP Fatal error: Cannot redeclare class PostFixture in /var/www/gutscheinpony/vendor/cakephp/cakephp/lib/Cake/Test/Fixture/PostFixture.php on line 51
Can I run my tests with the name Post or do I have to pick another name?
If not, why is there a PostFixture in the core anyway?
https://github.com/cakephp/cakephp/blob/2.6.13/lib/Cake/Test/Fixture/PostFixture.php
So I figured out why this happend.
You can load your own fixtures using
app.postin your test cases andcore.postto load the core fixtures.For some reason one of the plugins I use called the core fixture and caused the issue.