< prev index next >

test/hotspot/jtreg/runtime/SharedArchiveFile/DumpSymbolAndStringTable.java

Print this page




  54         try {
  55             output.shouldContain("16: java.lang.String\n");
  56         } catch (RuntimeException e) {
  57             output.shouldContain("Unknown diagnostic command");
  58         }
  59 
  60         pb.command(new String[] {JDKToolFinder.getJDKTool("jcmd"), pid, "VM.systemdictionary"});
  61         output = CDSTestUtils.executeAndLog(pb, "jcmd-systemdictionary");
  62         try {
  63             output.shouldContain("System Dictionary for jdk/internal/loader/ClassLoaders$AppClassLoader statistics:");
  64             output.shouldContain("Number of buckets");
  65             output.shouldContain("Number of entries");
  66             output.shouldContain("Maximum bucket size");
  67         } catch (RuntimeException e) {
  68             output.shouldContain("Unknown diagnostic command");
  69         }
  70 
  71         pb.command(new String[] {JDKToolFinder.getJDKTool("jcmd"), pid, "VM.systemdictionary", "-verbose"});
  72         output = CDSTestUtils.executeAndLog(pb, "jcmd-systemdictionary");
  73         try {
  74             output.shouldContain("Dictionary for class loader 0x");
  75             output.shouldContain("^java.lang.String");
  76         } catch (RuntimeException e) {
  77             output.shouldContain("Unknown diagnostic command");
  78         }
  79     }
  80 }


  54         try {
  55             output.shouldContain("16: java.lang.String\n");
  56         } catch (RuntimeException e) {
  57             output.shouldContain("Unknown diagnostic command");
  58         }
  59 
  60         pb.command(new String[] {JDKToolFinder.getJDKTool("jcmd"), pid, "VM.systemdictionary"});
  61         output = CDSTestUtils.executeAndLog(pb, "jcmd-systemdictionary");
  62         try {
  63             output.shouldContain("System Dictionary for jdk/internal/loader/ClassLoaders$AppClassLoader statistics:");
  64             output.shouldContain("Number of buckets");
  65             output.shouldContain("Number of entries");
  66             output.shouldContain("Maximum bucket size");
  67         } catch (RuntimeException e) {
  68             output.shouldContain("Unknown diagnostic command");
  69         }
  70 
  71         pb.command(new String[] {JDKToolFinder.getJDKTool("jcmd"), pid, "VM.systemdictionary", "-verbose"});
  72         output = CDSTestUtils.executeAndLog(pb, "jcmd-systemdictionary");
  73         try {
  74             output.shouldContain("Dictionary for loader data: 0x");
  75             output.shouldContain("^java.lang.String");
  76         } catch (RuntimeException e) {
  77             output.shouldContain("Unknown diagnostic command");
  78         }
  79     }
  80 }
< prev index next >