public class ClobUpdatableReaderTest extends BaseJDBCTestCase
UpdateableReader for Clob in
embedded driver.| Modifier and Type | Field and Description |
|---|---|
private java.lang.String |
dummy |
DEFAULT_DB_DIR, DERBY_LOG, ERRORSTACKTRACEFILE| Constructor and Description |
|---|
ClobUpdatableReaderTest(java.lang.String name) |
| Modifier and Type | Method and Description |
|---|---|
private int |
assertCorrectChar(int prevChar,
int nextChar)
Asserts that the two specified characters follow each other in the
modern latin lowercase alphabet.
|
private java.lang.String |
getUnicodeString()
Generates a (static) string containing various Unicode characters.
|
void |
setUp()
Setup the test.
|
static junit.framework.Test |
suite() |
protected void |
tearDown()
Cleans up the database.
|
void |
testMultiplexedOperationProblem()
Tests that the Clob can handle multiple streams and the length call
multiplexed.
|
void |
testUpdateableReader()
Tests updates on reader.
|
void |
testUpdateableStoreReader()
Test updating a large clob
|
assertCallError, assertCheckTable, assertCompileError, assertEquals, assertEquals, assertEquals, assertEquivalentDataType, assertErrorCode, assertGetIntError, assertNextError, assertPreparedStatementError, assertSQLExceptionEquals, assertSQLState, assertSQLState, assertStatementError, assertStatementError, assertStatementError, assertStatementError, assertStatementErrorUnordered, assertTableRowCount, assertUpdateCount, assertUpdateCount, assertWarning, checkAllConsistency, checkEstimatedRowCount, closeStatement, commit, createStatement, createStatement, createStatement, dropTable, dropTable, dropView, dropView, emptyStatementCache, getClientTransactionID, getConnection, getDatabaseProperty, getLastSQLException, initializeConnection, openConnection, openDefaultConnection, openDefaultConnection, openDefaultConnection, openUserConnection, prepareCall, prepareCall, prepareCall, prepareStatement, prepareStatement, prepareStatement, prepareStatement, prepareStatement, prepareStatement, rollback, runBare, runBareOverridable, runScript, runScript, runSQLCommands, setAutoCommit, usingDB2Client, usingDerbyNetClient, usingEmbeddedalarm, assertDirectoryDeleted, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertExecJavaCmdAsExpected, assertLaunchedJUnitTestMethod, assertLaunchedJUnitTestMethod, assertSecurityManager, assertThrowableEquals, currentDirectory, execJavaCmd, execJavaCmd, fail, getClassVersionMajor, getEmmaJar, getFailureFolder, getFilesWith, getJavaExecutableName, getSystemProperty, getTestConfiguration, getTestResource, hasInterruptibleIO, isCVM, isIBMJVM, isJ9Platform, isJava5, isJava7, isJava8, isPhoneME, isPlatform, isSunJVM, isWindowsPlatform, openTestResource, println, printStackTrace, readProcessOutput, removeDirectory, removeDirectory, removeFiles, removeSystemProperty, runsWithEmma, runsWithJaCoCo, setSystemProperty, sleep, sleepAtLeastOneTick, traceitassertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, countTestCases, createResult, fail, fail, failNotEquals, failNotSame, failSame, format, getName, run, run, runTest, setName, toStringprivate final java.lang.String dummy
public void testUpdateableStoreReader()
throws java.lang.Exception
java.lang.Exceptionpublic void testUpdateableReader()
throws java.lang.Exception
java.lang.Exceptionpublic void testMultiplexedOperationProblem()
throws java.io.IOException,
java.sql.SQLException
This test was written after bug DERBY-2806 was reported, where getting the length of the Clob after fetching a stream from it would exhaust the stream and cause the next read to return -1.
The test is written to work on a Clob that operates on streams from the store, which currently means that it must be over a certain size and that no modifying methods can be called on it.
java.io.IOExceptionjava.sql.SQLExceptionprivate int assertCorrectChar(int prevChar,
int nextChar)
throws java.io.IOException
java.io.IOExceptionprivate java.lang.String getUnicodeString()
public void setUp()
throws java.lang.Exception
setUp in class junit.framework.TestCasejava.sql.SQLException - if database access failsjava.lang.Exceptionpublic static junit.framework.Test suite()
protected void tearDown()
throws java.lang.Exception
tearDown in class BaseJDBCTestCasejava.lang.ExceptionApache Derby V10.10 Internals - Copyright © 2004,2014 The Apache Software Foundation. All Rights Reserved.