* due to Reference containing RefAddrs with null content.
*
* @throws Exception if the test fails
*/
public void testBug16791() throws Exception {
MysqlDataSource myDs = new MysqlDataSource();
myDs.setUrl(dbUrl);
Reference asRef = myDs.getReference();
System.out.println(asRef);
removeFromRef(asRef, "port");
removeFromRef(asRef, NonRegisteringDriver.USER_PROPERTY_KEY);
removeFromRef(asRef, NonRegisteringDriver.PASSWORD_PROPERTY_KEY);
removeFromRef(asRef, "serverName");
removeFromRef(asRef, "databaseName");
MysqlDataSource newDs = (MysqlDataSource)new MysqlDataSourceFactory().getObjectInstance(asRef, null, null, null);
}