final InputStream in = getInputStream("SampleSun1_7_0-02_G1_young.txt");
final DataReader reader = new DataReaderSun1_6_0G1(in, GcLogType.SUN1_7G1);
GCModel model = reader.read();
assertEquals("gc pause", 0.14482200, model.getPause().getMax(), 0.000000001);
GCEvent heap = (GCEvent) model.getEvents().next();
assertEquals("heap before", 1105*1024, heap.getPreUsed());
assertEquals("heap after", 380*1024, heap.getPostUsed());
assertEquals("heap", 2*1024*1024, heap.getTotal());
GCEvent young = model.getGCEvents().next().getYoung();
assertNotNull("young", young);
assertEquals("young before", 1024*1024, young.getPreUsed());
assertEquals("young after", 128*1024, young.getPostUsed());
assertEquals("young total", (896+128)*1024, young.getTotal());
GCEvent tenured = model.getGCEvents().next().getTenured();
assertNotNull("tenured", tenured);
assertEquals("tenured before", (1105-1024)*1024, tenured.getPreUsed());
assertEquals("tenured after", (380-128)*1024, tenured.getPostUsed());
assertEquals("tenured total", 1024*1024, tenured.getTotal());
assertEquals("number of errors", 0, handler.getCount());
}