Code example for SQLNonTransientException

Methods: getCause, getErrorCode, getMessage, getSQLState

0
 
    /** 
     * @test java.sql.SQLNonTransientException(String, String, int, Throwable) 
     */ 
    public void test_Constructor_LStringLStringILThrowable_23() { 
        SQLNonTransientException sQLNonTransientException = new SQLNonTransientException(
                null, null, -1, null); 
        assertNotNull(sQLNonTransientException);
        assertNull("The SQLState of SQLNonTransientException should be null",
                sQLNonTransientException.getSQLState());
        assertNull("The reason of SQLNonTransientException should be null",
                sQLNonTransientException.getMessage());
        assertEquals("The error code of SQLNonTransientException should be -1",
                sQLNonTransientException.getErrorCode(), -1);
        assertNull("The cause of SQLNonTransientException should be null",
                sQLNonTransientException.getCause());
    } 
 
    /** 
     * @test java.sql.SQLNonTransientException() 
     */