Skip to content

Commit

Permalink
In-progress test.
Browse files Browse the repository at this point in the history
  • Loading branch information
asgeirn committed Oct 24, 2011
1 parent 7d808f5 commit f5d54a5
Showing 1 changed file with 5 additions and 1 deletion.
Expand Up @@ -21,7 +21,7 @@ public class LockingCircularBufferTest {
@Test
public void testWait() throws InterruptedException, ExecutionException, TimeoutException {
final ExecutorService executor = Executors.newSingleThreadExecutor();
final CircularBuffer<Integer> buffer = new LockingCircularBuffer<Integer>(2, new ReentrantLock());
final CircularBuffer<Integer> buffer = new LockingCircularBuffer<Integer>(2, new ReentrantLock(true));
final AtomicInteger i = buffer.index();
Future<Integer> result = executor.submit(new Callable<Integer>() {
@Override
Expand All @@ -34,4 +34,8 @@ public Integer call() throws Exception {
assertThat(result.get(1, SECONDS), is(42));
}

@Test
public void manyReaders() throws Exception {

}
}

0 comments on commit f5d54a5

Please sign in to comment.