Package cat.quickdb.binding.model

Examples of cat.quickdb.binding.model.BindingObject.obtainWhere()


    @Test
    public void testObtainWhere(){
        BindingObject bind = new BindingObject();

        bind.obtainWhere("name = 'quickdb'");
        Assert.assertEquals("quickdb", bind.getName());
        Assert.assertEquals(3000.50, bind.getSalary());
    }

    @Test
View Full Code Here


        bind.setName("quickdb2");
        bind.setSalary(3000.50);

        int index = bind.saveGetIndex();
        Assert.assertTrue( (index > 0) );
        Assert.assertTrue(bind.obtainWhere("id = "+index));

        Assert.assertTrue(bind.delete());
    }

    @Test
View Full Code Here

        bind.setBirth(new java.sql.Date(104, 4, 20));
        bind.setName("quickdb3");
        bind.setSalary(3000.50);

        bind.save();
        Assert.assertTrue(bind.obtainWhere("name = 'quickdb3'"));
        bind.setName("quickdb4");

        Assert.assertTrue(bind.modify());

        BindingObject b = new BindingObject();
View Full Code Here

        bind.setName("quickdb4");

        Assert.assertTrue(bind.modify());

        BindingObject b = new BindingObject();
        Assert.assertTrue(b.obtainWhere("name = 'quickdb4'"));
        Assert.assertEquals("quickdb4", b.getName());
    }

    public static junit.framework.Test suite() {
        return new junit.framework.JUnit4TestAdapter(BindingTest.class);
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.