app.addEmbeddableCartridge(CartridgeTestUtils.mysql51());
// verifications
mockDirector.verifyAddEmbeddableCartridge("foobarz", "springeap6");
assertThat(app.getEmbeddedCartridges()).hasSize(2);
IEmbeddedCartridge mySqlCartridge = app.getEmbeddedCartridge(MYSQL_51_NAME);
new EmbeddedCartridgeAssert(mySqlCartridge)
.hasMessages()
.hasDescription()
.hasName(MYSQL_51_NAME);
new MessageAssert(mySqlCartridge.getMessages().getFirstBy(IField.DEFAULT))
.hasExitCode(-1)
.hasText("Added mysql-5.1 to application springeap6");
new MessageAssert(mySqlCartridge.getMessages().getFirstBy(IField.RESULT))
.hasExitCode(0)
.hasText(
"\nMySQL 5.1 database added. Please make note of these credentials:\n\n"
+ " Root User: adminnFC22YQ\n Root Password: U1IX8AIlrEcl\n Database Name: springeap6\n\n"
+ "Connection URL: mysql://$OPENSHIFT_MYSQL_DB_HOST:$OPENSHIFT_MYSQL_DB_PORT/\n\n"
+ "You can manage your new MySQL database by also embedding phpmyadmin-3.4.\n"
+ "The phpmyadmin username and password will be the same as the MySQL credentials above.\n");
new MessageAssert(mySqlCartridge.getMessages().getFirstBy(IField.APPINFO))
.hasExitCode(0)
.hasText("Connection URL: mysql://127.13.125.1:3306/\n");
}