@Override
    public void close() throws IOException {
      isClosed.set(true);
      real.close();
    }
A proxy around FSDataInputStream which can report if close() was called.
hbase-server/src/test/java/org/apache/hadoop/hbase/wal/TestWALFactory.java