super.setUp();
if (System.getSecurityManager() == null)
System.setSecurityManager(new java.rmi.RMISecurityManager());
getLog().info("Remove accounts");
{
AccountHome home = (AccountHome)PortableRemoteObject.narrow(
getInitialContext().lookup(AccountHome.JNDI_NAME),
AccountHome.class);
Collection accounts = home.findAll();
Iterator i = accounts.iterator();
while(i.hasNext())
{
Account acct = (Account)PortableRemoteObject.narrow(i.next(),
Account.class);
getLog().debug("Removing "+acct.getPrimaryKey());
acct.remove();
}
}
getLog().info("Remove customers");
{
CustomerHome home = (CustomerHome)PortableRemoteObject.narrow(
getInitialContext().lookup(CustomerHome.JNDI_NAME),
CustomerHome.class);
Collection customers = home.findAll();
Iterator i = customers.iterator();
while(i.hasNext())
{
Customer cust =
(Customer)PortableRemoteObject.narrow(i.next(),