Package org.apache.cayenne.testdo.mt

Examples of org.apache.cayenne.testdo.mt.ClientMtTable1.addToTable2Array()


    public void testAddToList() throws Exception {

        ClientMtTable1 t1 = clientContext.newObject(ClientMtTable1.class);
        ClientMtTable2 t2 = clientContext.newObject(ClientMtTable2.class);

        t1.addToTable2Array(t2);
        assertEquals(1, t1.getTable2Array().size());
        assertSame(t1, t2.getTable1());

        // do it again to make sure action can handle series of changes
        ClientMtTable1 t3 = clientContext.newObject(ClientMtTable1.class);
View Full Code Here


        // do it again to make sure action can handle series of changes
        ClientMtTable1 t3 = clientContext.newObject(ClientMtTable1.class);
        ClientMtTable2 t4 = clientContext.newObject(ClientMtTable2.class);

        t3.addToTable2Array(t4);
        assertEquals(1, t3.getTable2Array().size());
        assertSame(t3, t4.getTable1());
    }

    public void testSetValueHolder() throws Exception {
View Full Code Here

        };

        CayenneContext context = new CayenneContext(channel);
        ClientMtTable1 o = context.newObject(ClientMtTable1.class);
        ClientMtTable2 o2 = context.newObject(ClientMtTable2.class);
        o.addToTable2Array(o2);
        context.commitChanges();

        assertEquals(2, diffReader.size);

        diffReader.reset();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.