Description
DBServiceTest and ZMSBinderTest can fail because the test database is not ready to accept connections yet, see ZMSTestUtils.
This happens in DBServiceTest, for example, because the @BeforeClass method calls mysqld.getJdbcUrl() right away and the database isn't ready.
This does not happen in other tests like ZMSImplTest because there's enough time between @BeforeClass and @BeforeMethod for the database to start.
Proposed Solution
In ZMSTestUtils startMemoryMySQL add a method which verifies the database is ready to accept connections.
Description
DBServiceTest and ZMSBinderTest can fail because the test database is not ready to accept connections yet, see ZMSTestUtils.
This happens in
DBServiceTest, for example, because the@BeforeClassmethod callsmysqld.getJdbcUrl()right away and the database isn't ready.This does not happen in other tests like ZMSImplTest because there's enough time between
@BeforeClassand@BeforeMethodfor the database to start.Proposed Solution
In ZMSTestUtils startMemoryMySQL add a method which verifies the database is ready to accept connections.