// Path: src/main/java/org/ardverk/io/ProgressInputStream.java
// public static class ProgressAdapter implements ProgressCallback {
//   @Override
//   public void in(InputStream in, int count) {
//   }
// 
//   @Override
//   public void eof(InputStream in) {
//   }
// 
//   @Override
//   public void closed(InputStream in) {
//   }
// }
// 
// Path: src/main/java/org/ardverk/io/ProgressInputStream.java
// public static interface ProgressCallback {
//   /**
//    * Called every time some data has been read from 
//    * the {@link ProgressInputStream}.
//    */
//   public void in(InputStream in, int count);
//     
//   /**
//    * Called if the {@link ProgressInputStream}'s EOF has been reached.
//    */
//   public void eof(InputStream in);
//     
//   /**
//    * Called if the {@link ProgressInputStream} has been closed.
//    * 
//    * @see ProgressInputStream#close()
//    */
//   public void closed(InputStream in);
// }


import java.io.ByteArrayInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.util.concurrent.CountDownLatch;
import java.util.concurrent.TimeUnit;
import junit.framework.TestCase;
import org.ardverk.io.ProgressInputStream.ProgressAdapter;
import org.ardverk.io.ProgressInputStream.ProgressCallback;
import org.junit.Test;
package org.ardverk.io;




public class ProgressInputStreamTest {

  @Test
  public void close() throws IOException, InterruptedException {
    final CountDownLatch latch = new CountDownLatch(1);
// Path: src/main/java/org/ardverk/io/ProgressInputStream.java
// public static class ProgressAdapter implements ProgressCallback {
//   @Override
//   public void in(InputStream in, int count) {
//   }
// 
//   @Override
//   public void eof(InputStream in) {
//   }
// 
//   @Override
//   public void closed(InputStream in) {
//   }
// }
// 
// Path: src/main/java/org/ardverk/io/ProgressInputStream.java
// public static interface ProgressCallback {
//   /**
//    * Called every time some data has been read from 
//    * the {@link ProgressInputStream}.
//    */
//   public void in(InputStream in, int count);
//     
//   /**
//    * Called if the {@link ProgressInputStream}'s EOF has been reached.
//    */
//   public void eof(InputStream in);
//     
//   /**
//    * Called if the {@link ProgressInputStream} has been closed.
//    * 
//    * @see ProgressInputStream#close()
//    */
//   public void closed(InputStream in);
// }


// Path: src/test/java/org/ardverk/io/ProgressInputStreamTest.java
import java.io.ByteArrayInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.util.concurrent.CountDownLatch;
import java.util.concurrent.TimeUnit;
import junit.framework.TestCase;
import org.ardverk.io.ProgressInputStream.ProgressAdapter;
import org.ardverk.io.ProgressInputStream.ProgressCallback;
import org.junit.Test;

package org.ardverk.io;




public class ProgressInputStreamTest {

  @Test
  public void close() throws IOException, InterruptedException {
    final CountDownLatch latch = new CountDownLatch(1);
    ProgressCallback callback = new ProgressAdapter() {