Package org.apache.cayenne.testdo.mt

Examples of org.apache.cayenne.testdo.mt.ClientMtLifecycles


    public void testDefault() throws InterruptedException {
        ObjectContext context = createROPContext();
        context.getEntityResolver().getCallbackRegistry().addListener(ClientMtLifecycles.class, this);
       
        assertAll(0, 0, 0, 0, 0, 0, 0, 0);
        ClientMtLifecycles l1 = context.newObject(ClientMtLifecycles.class);
       
        assertAll(1, 0, 0, 0, 0, 0, 0, 0);
        l1.setName("x");
        assertAll(1, 0, 0, 0, 0, 0, 0, 0);
       
        context.commitChanges();
        Thread.sleep(5); //until commit
        assertAll(1, 0, 1, 1, 0, 0, 0, 0);
       
        l1.setName("x2");
        assertAll(1, 0, 1, 1, 0, 0, 0, 0);
       
        context.commitChanges();
        Thread.sleep(5); //until commit
        assertAll(1, 0, 1, 1, 1, 1, 0, 0);
View Full Code Here


    public void testDefault() throws InterruptedException {
        ObjectContext context = createROPContext();
        context.getEntityResolver().getCallbackRegistry().addListener(ClientMtLifecycles.class, this);
       
        assertAll(0, 0, 0, 0, 0, 0, 0, 0);
        ClientMtLifecycles l1 = context.newObject(ClientMtLifecycles.class);
       
        assertAll(1, 0, 0, 0, 0, 0, 0, 0);
        l1.setName("x");
        assertAll(1, 0, 0, 0, 0, 0, 0, 0);
       
        context.commitChanges();
        Thread.sleep(5); //until commit
        assertAll(1, 0, 1, 1, 0, 0, 0, 0);
       
        l1.setName("x2");
        assertAll(1, 0, 1, 1, 0, 0, 0, 0);
       
        context.commitChanges();
        Thread.sleep(5); //until commit
        assertAll(1, 0, 1, 1, 1, 1, 0, 0);
View Full Code Here

TOP

Related Classes of org.apache.cayenne.testdo.mt.ClientMtLifecycles

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.