Package java.sql

Examples of java.sql.SQLTimeoutException


    /**
     * @test java.sql.SQLTimeoutException(String)
     */
    public void test_Constructor_LString() {
        SQLTimeoutException sQLTimeoutException = new SQLTimeoutException(
                "MYTESTSTRING");
        assertNotNull(sQLTimeoutException);
        assertNull("The SQLState of SQLTimeoutException should be null",
                sQLTimeoutException.getSQLState());
        assertEquals(
                "The reason of SQLTimeoutException set and get should be equivalent",
                "MYTESTSTRING", sQLTimeoutException.getMessage());
        assertEquals("The error code of SQLTimeoutException should be 0",
                sQLTimeoutException.getErrorCode(), 0);
    }
View Full Code Here


    /**
     * @test java.sql.SQLTimeoutException(String)
     */
    public void test_Constructor_LString_1() {
        SQLTimeoutException sQLTimeoutException = new SQLTimeoutException(
                (String) null);
        assertNotNull(sQLTimeoutException);
        assertNull("The SQLState of SQLTimeoutException should be null",
                sQLTimeoutException.getSQLState());
        assertNull("The reason of SQLTimeoutException should be null",
                sQLTimeoutException.getMessage());
        assertEquals("The error code of SQLTimeoutException should be 0",
                sQLTimeoutException.getErrorCode(), 0);
    }
View Full Code Here

    /**
     * @test java.sql.SQLTimeoutException(String, String)
     */
    public void test_Constructor_LStringLString() {
        SQLTimeoutException sQLTimeoutException = new SQLTimeoutException(
                "MYTESTSTRING1", "MYTESTSTRING2");
        assertNotNull(sQLTimeoutException);
        assertEquals(
                "The SQLState of SQLTimeoutException set and get should be equivalent",
                "MYTESTSTRING2", sQLTimeoutException.getSQLState());
        assertEquals(
                "The reason of SQLTimeoutException set and get should be equivalent",
                "MYTESTSTRING1", sQLTimeoutException.getMessage());
        assertEquals("The error code of SQLTimeoutException should be 0",
                sQLTimeoutException.getErrorCode(), 0);

    }
View Full Code Here

    /**
     * @test java.sql.SQLTimeoutException(String, String)
     */
    public void test_Constructor_LStringLString_1() {
        SQLTimeoutException sQLTimeoutException = new SQLTimeoutException(
                "MYTESTSTRING", (String) null);
        assertNotNull(sQLTimeoutException);
        assertNull("The SQLState of SQLTimeoutException should be null",
                sQLTimeoutException.getSQLState());
        assertEquals(
                "The reason of SQLTimeoutException set and get should be equivalent",
                "MYTESTSTRING", sQLTimeoutException.getMessage());
        assertEquals("The error code of SQLTimeoutException should be 0",
                sQLTimeoutException.getErrorCode(), 0);
    }
View Full Code Here

    /**
     * @test java.sql.SQLTimeoutException(String, String)
     */
    public void test_Constructor_LStringLString_2() {
        SQLTimeoutException sQLTimeoutException = new SQLTimeoutException(null,
                "MYTESTSTRING");
        assertNotNull(sQLTimeoutException);
        assertEquals(
                "The SQLState of SQLTimeoutException set and get should be equivalent",
                "MYTESTSTRING", sQLTimeoutException.getSQLState());
        assertNull("The reason of SQLTimeoutException should be null",
                sQLTimeoutException.getMessage());
        assertEquals("The error code of SQLTimeoutException should be 0",
                sQLTimeoutException.getErrorCode(), 0);
    }
View Full Code Here

    /**
     * @test java.sql.SQLTimeoutException(String, String)
     */
    public void test_Constructor_LStringLString_3() {
        SQLTimeoutException sQLTimeoutException = new SQLTimeoutException(
                (String) null, (String) null);
        assertNotNull(sQLTimeoutException);
        assertNull("The SQLState of SQLTimeoutException should be null",
                sQLTimeoutException.getSQLState());
        assertNull("The reason of SQLTimeoutException should be null",
                sQLTimeoutException.getMessage());
        assertEquals("The error code of SQLTimeoutException should be 0",
                sQLTimeoutException.getErrorCode(), 0);
    }
View Full Code Here

    /**
     * @test java.sql.SQLTimeoutException(String, String, int)
     */
    public void test_Constructor_LStringLStringI() {
        SQLTimeoutException sQLTimeoutException = new SQLTimeoutException(
                "MYTESTSTRING1", "MYTESTSTRING2", 1);
        assertNotNull(sQLTimeoutException);
        assertEquals(
                "The SQLState of SQLTimeoutException set and get should be equivalent",
                "MYTESTSTRING2", sQLTimeoutException.getSQLState());
        assertEquals(
                "The reason of SQLTimeoutException set and get should be equivalent",
                "MYTESTSTRING1", sQLTimeoutException.getMessage());
        assertEquals("The error code of SQLTimeoutException should be 1",
                sQLTimeoutException.getErrorCode(), 1);
    }
View Full Code Here

    /**
     * @test java.sql.SQLTimeoutException(String, String, int)
     */
    public void test_Constructor_LStringLStringI_1() {
        SQLTimeoutException sQLTimeoutException = new SQLTimeoutException(
                "MYTESTSTRING1", "MYTESTSTRING2", 0);
        assertNotNull(sQLTimeoutException);
        assertEquals(
                "The SQLState of SQLTimeoutException set and get should be equivalent",
                "MYTESTSTRING2", sQLTimeoutException.getSQLState());
        assertEquals(
                "The reason of SQLTimeoutException set and get should be equivalent",
                "MYTESTSTRING1", sQLTimeoutException.getMessage());
        assertEquals("The error code of SQLTimeoutException should be 0",
                sQLTimeoutException.getErrorCode(), 0);
    }
View Full Code Here

    /**
     * @test java.sql.SQLTimeoutException(String, String, int)
     */
    public void test_Constructor_LStringLStringI_2() {
        SQLTimeoutException sQLTimeoutException = new SQLTimeoutException(
                "MYTESTSTRING1", "MYTESTSTRING2", -1);
        assertNotNull(sQLTimeoutException);
        assertEquals(
                "The SQLState of SQLTimeoutException set and get should be equivalent",
                "MYTESTSTRING2", sQLTimeoutException.getSQLState());
        assertEquals(
                "The reason of SQLTimeoutException set and get should be equivalent",
                "MYTESTSTRING1", sQLTimeoutException.getMessage());
        assertEquals("The error code of SQLTimeoutException should be -1",
                sQLTimeoutException.getErrorCode(), -1);
    }
View Full Code Here

    /**
     * @test java.sql.SQLTimeoutException(String, String, int)
     */
    public void test_Constructor_LStringLStringI_3() {
        SQLTimeoutException sQLTimeoutException = new SQLTimeoutException(
                "MYTESTSTRING", null, 1);
        assertNotNull(sQLTimeoutException);
        assertNull("The SQLState of SQLTimeoutException should be null",
                sQLTimeoutException.getSQLState());
        assertEquals(
                "The reason of SQLTimeoutException set and get should be equivalent",
                "MYTESTSTRING", sQLTimeoutException.getMessage());
        assertEquals("The error code of SQLTimeoutException should be 1",
                sQLTimeoutException.getErrorCode(), 1);
    }
View Full Code Here

TOP

Related Classes of java.sql.SQLTimeoutException

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.