Package org.apache.isis.runtimes.dflt.objectstores.sql.testsystem.dataclasses

Examples of org.apache.isis.runtimes.dflt.objectstores.sql.testsystem.dataclasses.SqlDataClass


    /**
     * Test {@link TimeStamp} type.
     */
    public void testTimeStamp() {
        final SqlDataClass sqlDataClass = SqlIntegrationTestSingleton.getDataClass();
        assertTrue("TimeStamp " + timeStamp.toString() + " is not equal to " + sqlDataClass.getTimeStamp().toString(), timeStamp.isEqualTo(sqlDataClass.getTimeStamp()));
    }
View Full Code Here


    /**
     * Test {@link Time} type.
     */
    /**/
    public void testTime() {
        final SqlDataClass sqlDataClass = SqlIntegrationTestSingleton.getDataClass();
        assertNotNull("sqlDataClass is null", sqlDataClass);
        assertNotNull("getTime() is null", sqlDataClass.getTime());
        assertTrue("Time 14h56: expected " + time.toString() + ", but got " + sqlDataClass.getTime().toString(), time.isEqualTo(sqlDataClass.getTime()));
    }
View Full Code Here

    /**
     * Test {@link Color} type.
     */
    public void testColor() {
        final SqlDataClass sqlDataClass = SqlIntegrationTestSingleton.getDataClass();
        assertEquals(color, sqlDataClass.getColor());
        // assertTrue("Color Black, expected " + color.toString() + " but got "
        // + sqlDataClass.getColor().toString(),
        // color.isEqualTo(sqlDataClass.getColor()));
    }
View Full Code Here

    /**
     * Test {@link Password} type.
     */
    public void testPassword() {
        final SqlDataClass sqlDataClass = SqlIntegrationTestSingleton.getDataClass();
        assertEquals(password, sqlDataClass.getPassword());
    }
View Full Code Here

    /**
     * Test {@link Percentage} type.
     */
    public void testPercentage() {
        final SqlDataClass sqlDataClass = SqlIntegrationTestSingleton.getDataClass();
        assertEquals(percentage, sqlDataClass.getPercentage());
    }
View Full Code Here

        final SqlDataClass sqlDataClass = SqlIntegrationTestSingleton.getDataClass();
        assertEquals(percentage, sqlDataClass.getPercentage());
    }

    public void testStandardValueTypesMaxima() {
        final SqlDataClass sqlDataClass = SqlIntegrationTestSingleton.getDataClass();
        final NumericTestClass numericTestMaxClass = sqlDataClass.getNumericTestClassMax();

        assertEquals(shortMaxValue, numericTestMaxClass.getShortValue());
        assertEquals(intMaxValue, numericTestMaxClass.getIntValue());
        assertEquals(longMaxValue, numericTestMaxClass.getLongValue());
        assertEquals(doubleMaxValue, numericTestMaxClass.getDoubleValue()); // fails
View Full Code Here

                                                                            // infinity
        assertEquals(floatMaxValue, numericTestMaxClass.getFloatValue());
    }

    public void testStandardValueTypesMinima() {
        final SqlDataClass sqlDataClass = SqlIntegrationTestSingleton.getDataClass();
        final NumericTestClass numericTestMinClass = sqlDataClass.getNumericTestClassMin();

        assertEquals(shortMinValue, numericTestMinClass.getShortValue());
        assertEquals(intMinValue, numericTestMinClass.getIntValue());
        assertEquals(longMinValue, numericTestMinClass.getLongValue());
        assertEquals(doubleMinValue, numericTestMinClass.getDoubleValue()); // fails
View Full Code Here

     * collection) { assertEquals(SqlIntegrationTestCommon.stringList.get(i++),
     * string); } }
     */

    public void testSingleReferenceLazy() {
        final SqlDataClass sqlDataClass = SqlIntegrationTestSingleton.getDataClass();
        final SimpleClassTwo a = sqlDataClass.getSimpleClassTwo();
        if (getProperties().getProperty("isis.persistor") != "in-memory") {
            assertEquals(null, a.text); // must check direct value, as
            // framework can auto-resolve, if you use getText()
        }
    }
View Full Code Here

    /**
     * Test a collection of {@link SimpleClass} type.
     */
    public void testSimpleClassCollection1() {
        final SqlDataClass sqlDataClass = SqlIntegrationTestSingleton.getDataClass();
        final List<SimpleClass> collection = sqlDataClass.getSimpleClasses1();

        assertEquals("collection size is not equal!", SqlIntegrationTestCommon.simpleClassList1.size(), collection.size());

        int i = 0;
        for (final SimpleClass simpleClass : SqlIntegrationTestCommon.simpleClassList1) {
View Full Code Here

    /**
     * Test another collection of {@link SimpleClass} type.
     */
    /**/
    public void testSimpleClassCollection2() {
        final SqlDataClass sqlDataClass = SqlIntegrationTestSingleton.getDataClass();
        final List<SimpleClass> collection = sqlDataClass.getSimpleClasses2();

        assertEquals("collection size is not equal!", SqlIntegrationTestCommon.simpleClassList2.size(), collection.size());

        int i = 0;
        for (final SimpleClass simpleClass : SqlIntegrationTestCommon.simpleClassList2) {
View Full Code Here

TOP

Related Classes of org.apache.isis.runtimes.dflt.objectstores.sql.testsystem.dataclasses.SqlDataClass

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.