|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Objectjunit.framework.Assert
junit.framework.TestCase
JSR166TestCase
AtomicLongTest
public class AtomicLongTest
| Nested Class Summary |
|---|
| Field Summary |
|---|
| Fields inherited from class JSR166TestCase |
|---|
eight, expensiveTests, five, four, 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, three, two, zero |
| Constructor Summary | |
|---|---|
AtomicLongTest()
|
|
| Method Summary | |
|---|---|
static void |
main(java.lang.String[] args)
|
static junit.framework.Test |
suite()
|
void |
testAddAndGet()
addAndGet adds given value to current, and returns current value |
void |
testCompareAndSet()
compareAndSet succeeds in changing value if equal to expected else fails |
void |
testCompareAndSetInMultipleThreads()
compareAndSet in one thread enables another waiting for value to succeed |
void |
testConstructor()
constructor initializes to given value |
void |
testConstructor2()
default constructed initializes to zero |
void |
testDecrementAndGet()
decrementAndGet decrements and returns current value |
void |
testDoubleValue()
doubleValue returns current value. |
void |
testFloatValue()
floatValue returns current value. |
void |
testGetAndAdd()
getAndAdd returns previous value and adds given value |
void |
testGetAndDecrement()
getAndDecrement returns previous value and decrements |
void |
testGetAndIncrement()
getAndIncrement returns previous value and increments |
void |
testGetAndSet()
getAndSet returns previous value and sets to given value |
void |
testGetLazySet()
get returns the last value lazySet in same thread |
void |
testGetSet()
get returns the last value set |
void |
testIncrementAndGet()
incrementAndGet increments and returns current value |
void |
testIntValue()
intValue returns current value. |
void |
testLongValue()
longValue returns current value. |
void |
testSerialization()
a deserialized serialized atomic holds same value |
void |
testToString()
toString returns current value. |
void |
testWeakCompareAndSet()
repeated weakCompareAndSet succeeds in changing value when equal to expected |
| Methods inherited from class junit.framework.TestCase |
|---|
countTestCases, createResult, getName, run, run, runBare, setName, 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, failNotEquals, failNotSame, failSame, format |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public AtomicLongTest()
| Method Detail |
|---|
public static void main(java.lang.String[] args)
public static junit.framework.Test suite()
public void testConstructor()
public void testConstructor2()
public void testGetSet()
public void testGetLazySet()
public void testCompareAndSet()
public void testCompareAndSetInMultipleThreads()
throws java.lang.Exception
java.lang.Exceptionpublic void testWeakCompareAndSet()
public void testGetAndSet()
public void testGetAndAdd()
public void testGetAndDecrement()
public void testGetAndIncrement()
public void testAddAndGet()
public void testDecrementAndGet()
public void testIncrementAndGet()
public void testSerialization()
throws java.lang.Exception
java.lang.Exceptionpublic void testToString()
public void testIntValue()
public void testLongValue()
public void testFloatValue()
public void testDoubleValue()
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||