org.apache.derbyTesting.unitTests.junit
Class BlockedByteArrayTest

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by org.apache.derbyTesting.junit.BaseTestCase
              extended by org.apache.derbyTesting.unitTests.junit.BlockedByteArrayTest
All Implemented Interfaces:
junit.framework.Test

public class BlockedByteArrayTest
extends BaseTestCase

Basic tests of the BlockedByteArrayTest.


Field Summary
 
Fields inherited from class org.apache.derbyTesting.junit.BaseTestCase
DEFAULT_DB_DIR, DERBY_LOG, ERRORSTACKTRACEFILE
 
Constructor Summary
BlockedByteArrayTest(java.lang.String name)
           
 
Method Summary
private  org.apache.derby.impl.io.vfmem.BlockedByteArray createBlockedByteArray(long length)
          Creates a blocked byte array and fills it with data.
static junit.framework.Test suite()
           
 void testCapacityGrowth()
          Performs a series of capacity changes.
 void testLength()
           
 void testLengthNoInitialBlocksWriteMultipleBytes4K()
           
 void testLengthNoInitialBlocksWriteMultipleBytes4KPlussAFew()
           
 void testLengthNoInitialBlocksWriteSingleByte()
           
 void testReadArray()
           
 void testReadSingle()
           
 
Methods inherited from class org.apache.derbyTesting.junit.BaseTestCase
alarm, assertEquals, assertEquals, assertEquals, assertExecJavaCmdAsExpected, assertSecurityManager, assertThrowableEquals, execJavaCmd, fail, getFailureFolder, getJavaExecutableName, getSystemProperty, getTestConfiguration, getTestResource, openTestResource, println, printStackTrace, readProcessOutput, removeDirectory, removeDirectory, removeSystemProperty, runBare, setSystemProperty, traceit
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runTest, setName, setUp, tearDown, toString
 
Methods inherited from class junit.framework.Assert
assertEquals, 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, fail, fail
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BlockedByteArrayTest

public BlockedByteArrayTest(java.lang.String name)
Method Detail

testLengthNoInitialBlocksWriteSingleByte

public void testLengthNoInitialBlocksWriteSingleByte()

testLengthNoInitialBlocksWriteMultipleBytes4K

public void testLengthNoInitialBlocksWriteMultipleBytes4K()

testLengthNoInitialBlocksWriteMultipleBytes4KPlussAFew

public void testLengthNoInitialBlocksWriteMultipleBytes4KPlussAFew()

testReadArray

public void testReadArray()
                   throws java.io.IOException
Throws:
java.io.IOException

testReadSingle

public void testReadSingle()
                    throws java.io.IOException
Throws:
java.io.IOException

testLength

public void testLength()
                throws java.io.IOException
Throws:
java.io.IOException

testCapacityGrowth

public void testCapacityGrowth()
                        throws java.io.IOException
Performs a series of capacity changes.

Throws:
java.io.IOException - if something goes wrong

suite

public static junit.framework.Test suite()

createBlockedByteArray

private org.apache.derby.impl.io.vfmem.BlockedByteArray createBlockedByteArray(long length)
                                                                        throws java.io.IOException
Creates a blocked byte array and fills it with data.

Parameters:
length - requested length
Returns:
A filled blocked byte array.
Throws:
java.io.IOException - if reading from the source fails

Built on Sat 2009-11-28 18:44:18-0800, from revision 885187

Apache Derby V10.6 Internals - Copyright © 2004,2008 The Apache Software Foundation. All Rights Reserved.