Examples of invariantHolds()


Examples of org.apache.derby.iapi.services.io.FormatableBitSet.invariantHolds()

    public void testIntCtor0() {
        FormatableBitSet zeroBits = new FormatableBitSet(0);
        assertEquals(0,zeroBits.getLength());
        assertEquals(0,zeroBits.getLengthInBytes());
        assertEquals(0,zeroBits.getNumBitsSet());
        assertTrue(zeroBits.invariantHolds());
        assertEquals(0,zeroBits.getByteArray().length);
    }
    public void testIntCtor1() {
        FormatableBitSet oneBit = new FormatableBitSet(1);
        assertEquals(1,oneBit.getLength());
View Full Code Here

Examples of org.apache.derby.iapi.services.io.FormatableBitSet.invariantHolds()

    public void testIntCtor1() {
        FormatableBitSet oneBit = new FormatableBitSet(1);
        assertEquals(1,oneBit.getLength());
        assertEquals(1,oneBit.getLengthInBytes());
        assertEquals(0,oneBit.getNumBitsSet());
        assertTrue(oneBit.invariantHolds());
        assertEquals(1,oneBit.getByteArray().length);
    }
    public void testIntCtor8() {
        FormatableBitSet eightBits = new FormatableBitSet(8);
        assertEquals(8,eightBits.getLength());
View Full Code Here

Examples of org.apache.derby.iapi.services.io.FormatableBitSet.invariantHolds()

    public void testIntCtor8() {
        FormatableBitSet eightBits = new FormatableBitSet(8);
        assertEquals(8,eightBits.getLength());
        assertEquals(1,eightBits.getLengthInBytes());
        assertEquals(0,eightBits.getNumBitsSet());
        assertTrue(eightBits.invariantHolds());
        assertEquals(1,eightBits.getByteArray().length);
    }
    public void testIntCtor9() {
        FormatableBitSet nineBits = new FormatableBitSet(9);
        assertEquals(9,nineBits.getLength());
View Full Code Here

Examples of org.apache.derby.iapi.services.io.FormatableBitSet.invariantHolds()

    public void testIntCtor9() {
        FormatableBitSet nineBits = new FormatableBitSet(9);
        assertEquals(9,nineBits.getLength());
        assertEquals(2,nineBits.getLengthInBytes());
        assertEquals(0,nineBits.getNumBitsSet());
        assertTrue(nineBits.invariantHolds());
        assertEquals(2,nineBits.getByteArray().length);
    }
    public void testIntCtorNeg() {
        try { FormatableBitSet negBits = new FormatableBitSet(-1); fail(); }
        catch(IllegalArgumentException iae) {}
View Full Code Here

Examples of org.apache.derby.iapi.services.io.FormatableBitSet.invariantHolds()

    public void testEmptyCpyCtor() {
        FormatableBitSet emptyCpy = new FormatableBitSet(empty);
        assertEquals(0,emptyCpy.getLength());
        assertEquals(0,emptyCpy.getLengthInBytes());
        assertEquals(0,emptyCpy.getNumBitsSet());
        assertTrue(emptyCpy.invariantHolds());
    }
    public void testCpyCtor() {
        FormatableBitSet cpy = new FormatableBitSet(bitset18);
        assertEquals(18,cpy.getLength());
        assertEquals(3,cpy.getLengthInBytes());
View Full Code Here

Examples of org.apache.derby.iapi.services.io.FormatableBitSet.invariantHolds()

        assertEquals(18,cpy.getLength());
        assertEquals(3,cpy.getLengthInBytes());
        assertEquals(9,cpy.getNumBitsSet());
        assertEquals(0,cpy.compare(bitset18));
        assertTrue(cpy.equals(bitset18));
        assertTrue(cpy.invariantHolds());
        assertEquals(3,cpy.getByteArray().length);
    }

    // Test cases for grow(int)
    public void testGrowEmpty() {
View Full Code Here

Examples of org.apache.derby.iapi.services.io.FormatableBitSet.invariantHolds()

    public void testIntCtor0() {
        FormatableBitSet zeroBits = new FormatableBitSet(0);
        assertEquals(0,zeroBits.getLength());
        assertEquals(0,zeroBits.getLengthInBytes());
        assertEquals(0,zeroBits.getNumBitsSet());
        assertTrue(zeroBits.invariantHolds());
        assertEquals(0,zeroBits.getByteArray().length);
    }
    public void testIntCtor1() {
        FormatableBitSet oneBit = new FormatableBitSet(1);
        assertEquals(1,oneBit.getLength());
View Full Code Here

Examples of org.apache.derby.iapi.services.io.FormatableBitSet.invariantHolds()

    public void testIntCtor1() {
        FormatableBitSet oneBit = new FormatableBitSet(1);
        assertEquals(1,oneBit.getLength());
        assertEquals(1,oneBit.getLengthInBytes());
        assertEquals(0,oneBit.getNumBitsSet());
        assertTrue(oneBit.invariantHolds());
        assertEquals(1,oneBit.getByteArray().length);
    }
    public void testIntCtor8() {
        FormatableBitSet eightBits = new FormatableBitSet(8);
        assertEquals(8,eightBits.getLength());
View Full Code Here

Examples of org.apache.derby.iapi.services.io.FormatableBitSet.invariantHolds()

    public void testIntCtor8() {
        FormatableBitSet eightBits = new FormatableBitSet(8);
        assertEquals(8,eightBits.getLength());
        assertEquals(1,eightBits.getLengthInBytes());
        assertEquals(0,eightBits.getNumBitsSet());
        assertTrue(eightBits.invariantHolds());
        assertEquals(1,eightBits.getByteArray().length);
    }
    public void testIntCtor9() {
        FormatableBitSet nineBits = new FormatableBitSet(9);
        assertEquals(9,nineBits.getLength());
View Full Code Here

Examples of org.apache.derby.iapi.services.io.FormatableBitSet.invariantHolds()

    public void testIntCtor9() {
        FormatableBitSet nineBits = new FormatableBitSet(9);
        assertEquals(9,nineBits.getLength());
        assertEquals(2,nineBits.getLengthInBytes());
        assertEquals(0,nineBits.getNumBitsSet());
        assertTrue(nineBits.invariantHolds());
        assertEquals(2,nineBits.getByteArray().length);
    }
    public void testIntCtorNeg() {
        try { FormatableBitSet negBits = new FormatableBitSet(-1); fail(); }
        catch(IllegalArgumentException iae) {}
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.