### Question:
FileSystemState implements Closeable { public boolean isOpen() { return open.get(); } FileSystemState(Runnable onClose); boolean isOpen(); void checkOpen(); C register(C resource); void unregister(Closeable resource); @Override void close();  }### Answer:
@Test public void testIsOpen() throws IOException { assertTrue(state.isOpen()); state.close(); assertFalse(state.isOpen()); }