Bug #35007

Functional tests do not work with MySQL database

Added by Christopher Hlubek over 9 years ago. Updated over 9 years ago.

Status:
Resolved
Priority:
Must have
Category:
- Testing -
Start date:
2012-03-19
Due date:
% Done:

100%

Estimated time:
PHP Version:
Has patch:
No
Complexity:

Description

If persistence is enabled in functional tests and a MySQL database is configured, I get the following error when executing the test on a clean database:

1) Planetflow3\Tests\Functional\Controller\StandardControllerTest::indexActionWithoutParametersDisplaysRecentItems
PDOException: SQLSTATE[42S01]: Base table or view already exists: 1050 Table 'persistence_testentity' already exists

/Volumes/Data/Work/FLOW3/Planetflow3/Packages/Framework/Doctrine.DBAL/Classes/Connection.php:633
/Volumes/Data/Work/FLOW3/Planetflow3/Packages/Framework/Doctrine.ORM/Classes/Tools/SchemaTool.php:671
/Volumes/Data/Work/FLOW3/Planetflow3/Data/Temporary/Testing/Cache/Code/FLOW3_Object_Classes/TYPO3_FLOW3_Persistence_Doctrine_PersistenceManager_Original.php:271
/Volumes/Data/Work/FLOW3/Planetflow3/Packages/Framework/TYPO3.FLOW3/Tests/FunctionalTestCase.php:119
/Volumes/Data/Work/FLOW3/Planetflow3/Packages/Application/Planetflow3/Tests/Functional/Controller/StandardControllerTest.php:38
/Volumes/Data/Work/FLOW3/Planetflow3/Packages/Framework/TYPO3.FLOW3/Tests/BaseTestCase.php:49

Also available in: Atom PDF