public class TestCacheBeanData extends BaseTestCase {
@Test
public void testCacheBeanExtractAndLoad() {
SpiEbeanServer server = (SpiEbeanServer)Ebean.getServer(null);
BeanDescriptor<Customer> desc = server.getBeanDescriptor(Customer.class);
Customer c = new Customer();
c.setId(98989);
c.setName("Rob");
c.setCretime(new Timestamp(System.currentTimeMillis()));
c.setUpdtime(new Timestamp(System.currentTimeMillis()));
c.setStatus(Status.ACTIVE);
c.setSmallnote("somenote");
Address billingAddress = new Address();
billingAddress.setId((short)12);
billingAddress.setCity("Auckland");
billingAddress.setCountry(server.getReference(Country.class, "NZ"));
billingAddress.setLine1("92 Someplace Else");
c.setBillingAddress(billingAddress);
((EntityBean)c)._ebean_getIntercept().setNewBeanForUpdate();