@Override
  public void close() throws IOException {
    if (!closed) {
      try {
        super.close();
      }
      finally {
        closed = true;
      }
    }
  }
@Test
  public void  testClose() {
    TestCompressorStream testCompressorStream = new TestCompressorStream();
    try {
      testCompressorStream.close(); 
    }
    catch(IOException e) {
      System.out.println("Expected IOException");
    }
    Assert.assertTrue("closed shoud be true", 
        ((CompressorStream)testCompressorStream).closed);
    //cleanup after test case
    file.delete();
  }