ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/jsr166/jsr166/etc/testcases/AtomicBooleanTest.java
Revision: 1.3
Committed: Wed May 14 21:30:37 2003 UTC (21 years ago) by tim
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +0 -0 lines
State: FILE REMOVED
Log Message:
Moved main source rooted at . to ./src/main
Moved test source rooted at ./etc/testcases to ./src/test

File Contents

# Content
1 import java.util.concurrent.atomic.AtomicBoolean;
2 import junit.framework.TestCase;
3
4 /**
5 * Tests the AtomicBoolean implementation.
6 */
7 public class AtomicBooleanTest extends TestCase {
8
9 public void testGetAndSet () {
10 boolean initval = false;
11 AtomicBoolean b = new AtomicBoolean(initval);
12 boolean newval = true;
13 if (false /* remove once this is implemented */) {
14 assertEquals("getAndSet should return initial value,",
15 initval, b.getAndSet(newval));
16 assertEquals("get should return new value,",
17 newval, b.get());
18 }
19 }
20 }