Hi,
I'm developping a CakePHP application. The application has about 1500 tests which take about 4 hours to run sequentially. Therefore I want to use parallel pipelines to run 10 tests at the same time.
CakePHP tests create, delete and empty tables on most of the tests, so when alle 10 pipelines this can be a problem, when 1 test is using a table and the other one deletes it.
I've configured the 10 pipelines and written a custom PHP script that generates a PHPUnit test-suite for each of these 10 pipelines. Each test suite sets a DB_NAME environment variable so each pipeline can run on another database. I've added custom PHP code to create the database when it does not exists.
Locally, everything works perfect. However, when running the tests in Bitbucket pipelines I get the error: "Access denied for user 'testuser'@'%' to database 'test6'". So the default user can't create new databases next to the default "pipelines" database. And the documentation mentions no other users and also mentions that the root user is not available.
How can I fix this so I can run parallel tests? Waiting 4 hours to finish testing is not an option.