@Test
public void testDumpTree() throws Exception {

  final INode root = fsdir.getINode("/");
  LOG.info("Original tree");
  final StringBuffer b1 = root.dumpTreeRecursively();
  System.out.println("b1=" + b1);
  final BufferedReader in = new BufferedReader(new StringReader(b1.toString()));
  
  String line = in.readLine();
  checkClassName(line);
  for(; (line = in.readLine()) != null; ) {
    line = line.trim();
    if (!line.isEmpty() && !line.contains("snapshot")) {
      Assert.assertTrue("line=" + line,
          line.startsWith(INodeDirectory.DUMPTREE_LAST_ITEM)
          || line.startsWith(INodeDirectory.DUMPTREE_EXCEPT_LAST_ITEM));
      checkClassName(line);
    }
  }
}