i.next();
assertFalse(i.hasNext());
}
public void testRAM() throws Exception {
RAMDriver driver = new RAMDriver();
driver.add("/foo", "bar");
Path root = driver.root();
assertEquals(Path.get("/"), root);
Path foo = driver.child(root, "foo");
assertNotNull(foo);
Iterator<InputStream> in = driver.open(foo);
assertTrue(in.hasNext());
String file = Utils.readAsUTF8(in.next());
assertFalse(in.hasNext());
assertEquals("bar", file);
}