IFileSystem fs = new FileSystem(Constants.ROOT_PATH);
fs.create(0);
fs.open();
Block b = new Block(new BlockId(0));
byte[] content = "<test> <content> Hello world! </content> </test>".getBytes();
b.setBytes(content);
Block b2 = new Block(new BlockId(0));
b.setBytes(content);
BlockId bid = fs.append(b, false);
BlockId bid2 = fs.append(b2, false);
assertEquals(0, bid.getContainerId());
assertEquals(0, bid.getSegmentId());
assertEquals(0, bid.getId());
assertEquals(0, bid2.getContainerId());
assertEquals(0, bid2.getSegmentId());
assertEquals(1, bid2.getId());
fs.close();
}