public class CopyOnWriteArraySetTest extends JSR166TestCase
JSR166TestCase.AdjustablePolicy, JSR166TestCase.CallableOne, JSR166TestCase.CheckedBarrier, JSR166TestCase.CheckedCallable<T>, JSR166TestCase.CheckedInterruptedCallable<T>, JSR166TestCase.CheckedInterruptedRunnable, JSR166TestCase.CheckedRecursiveAction, JSR166TestCase.CheckedRecursiveTask<T>, JSR166TestCase.CheckedRunnable, JSR166TestCase.LongPossiblyInterruptedRunnable, JSR166TestCase.MediumInterruptedRunnable, JSR166TestCase.MediumPossiblyInterruptedRunnable, JSR166TestCase.MediumRunnable, JSR166TestCase.NoOpCallable, JSR166TestCase.NoOpREHandler, JSR166TestCase.NoOpRunnable, JSR166TestCase.NPETask, JSR166TestCase.RunnableShouldThrow, JSR166TestCase.ShortInterruptedRunnable, JSR166TestCase.ShortRunnable, JSR166TestCase.SimpleThreadFactory, JSR166TestCase.SmallCallable, JSR166TestCase.SmallPossiblyInterruptedRunnable, JSR166TestCase.SmallRunnable, JSR166TestCase.StringTask, JSR166TestCase.ThreadShouldThrow, JSR166TestCase.TrackedCallable, JSR166TestCase.TrackedLongRunnable, JSR166TestCase.TrackedMediumRunnable, JSR166TestCase.TrackedNoOpRunnable, JSR166TestCase.TrackedRunnable, JSR166TestCase.TrackedShortRunnable, JSR166TestCase.TrackedSmallRunnable
eight, expensiveTests, five, four, JAVA_CLASS_VERSION, JAVA_SPECIFICATION_VERSION, LONG_DELAY_MS, m1, m10, m2, m3, m4, m5, m6, MEDIUM_DELAY_MS, nine, one, seven, SHORT_DELAY_MS, six, SIZE, SMALL_DELAY_MS, TEST_STRING, testImplementationDetails, three, two, zero
Constructor and Description |
---|
CopyOnWriteArraySetTest() |
Modifier and Type | Method and Description |
---|---|
void |
testAdd2()
add will not add the element if it already exists in the set
|
void |
testAdd3()
add adds the element when it does not exist in the set
|
void |
testAddAll_idempotent()
addAll is idempotent
|
void |
testAddAll()
addAll adds each non-duplicate element from the given collection
|
void |
testAddAll2()
addAll adds each non-duplicate element from the given collection
|
void |
testClear()
clear removes all elements from the set
|
void |
testConstructor()
Default-constructed set is empty
|
void |
testConstructor3()
Collection-constructed set holds all of its elements
|
void |
testContains()
contains returns true for added elements
|
void |
testContainsAll()
containsAll returns true for collections with subset of elements
|
void |
testEmptyIterator()
iterator of empty collection has no elements
|
void |
testEquals()
Sets with equal elements are equal
|
void |
testIsEmpty()
isEmpty is true when empty, else false
|
void |
testIterator()
iterator() returns an iterator containing the elements of the
set in insertion order
|
void |
testIteratorRemove()
iterator remove is unsupported
|
void |
testRemove()
remove removes an element
|
void |
testRemoveAll()
removeAll removes all elements from the given collection
|
void |
testSerialization()
A deserialized serialized set is equal
|
void |
testSize()
size returns the number of elements
|
void |
testToArray_ArrayStoreException()
toArray throws an ArrayStoreException when the given array can
not store the objects inside the set
|
void |
testToArray()
toArray() returns an Object array containing all elements from
the set in insertion order
|
void |
testToArray2()
toArray(Integer array) returns an Integer array containing all
elements from the set in insertion order
|
void |
testToString()
toString holds toString of elements
|
addNamedTestClasses, assertIteratorExhausted, assertThrows, atLeastJava10, atLeastJava6, atLeastJava7, atLeastJava8, atLeastJava9, await, await, await, awaiter, countDowner, getShortDelay, jdk8ParameterizedTestSuite, latchAwaitingStringTask, newTestSuite, parameterizedTestSuite, permissivePolicy, possiblyInterruptedRunnable, runBare, runTest, runTestProfiled, runWithoutPermissions, runWithPermissions, runWithSecurityManagerWithPermissions, setDelays, setUp, shouldThrow, shouldThrow, tearDown, testMethodNames, threadAssertEquals, threadAssertEquals, threadAssertFalse, threadAssertNull, threadAssertSame, threadAssertTrue, threadFail, threadRecordFailure, threadShouldThrow, threadShouldThrow, threadUnexpectedException, trackedRunnable
public void testConstructor()
public void testConstructor3()
public void testAddAll()
public void testAddAll2()
public void testAdd2()
public void testAdd3()
public void testClear()
public void testContains()
public void testEquals()
public void testContainsAll()
public void testIsEmpty()
public void testIterator()
public void testEmptyIterator()
public void testIteratorRemove()
public void testToString()
public void testRemoveAll()
public void testRemove()
public void testSize()
public void testToArray()
public void testToArray2()
public void testToArray_ArrayStoreException()
public void testSerialization() throws Exception
Exception