Skip to content

Commit

Permalink
update test case (#257)
Browse files Browse the repository at this point in the history
  • Loading branch information
kkdlau committed Jun 20, 2024
1 parent 277caee commit 7b67eae
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -66,11 +66,11 @@ public void analyze(String gcLogFile) {
fail(e.getMessage());
}
Assertions.assertEquals( 2.193d, terminationAggregation.getStartTime().getTimeStamp(),0.001d, "Time of first event");
Assertions.assertEquals( 608800.088d, heapOccupancyAfterCollectionSummary.estimatedRuntime(),0.001d, "Runtime duration");
Assertions.assertEquals( 608797.895d, heapOccupancyAfterCollectionSummary.estimatedRuntime(),0.001d, "Runtime duration");

}

@Aggregates({EventSource.CMS_PREUNIFIED,EventSource.CMS_UNIFIED,EventSource.G1GC,EventSource.GENERATIONAL,EventSource.JVM,EventSource.SHENANDOAH, EventSource.TENURED,EventSource.ZGC})
@Aggregates({EventSource.GENERATIONAL,EventSource.CMS_UNIFIED,EventSource.G1GC,EventSource.GENERATIONAL,EventSource.JVM,EventSource.SHENANDOAH, EventSource.TENURED,EventSource.ZGC})

This comment has been minimized.

Copy link
@dsgrieve

dsgrieve Jun 20, 2024

Member

Was this intentional? EventSource.GENERATIONAL is already in the list. Did you mean to take CMS_PREUNIFIED out?

public static class JVMEventTerminationAggregator extends Aggregator<JVMTerminationEventAggregation> {

public JVMEventTerminationAggregator(JVMTerminationEventAggregation aggregation) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,11 @@ public void compareRuntimeDurations() {
}

jvm.getAggregation(OneRuntimeReport.class).ifPresentOrElse(
oneRuntimeReport -> Assertions.assertEquals(8.782d, oneRuntimeReport.getRuntimeDuration()),
oneRuntimeReport -> Assertions.assertEquals(8.772d, oneRuntimeReport.getRuntimeDuration()),
() -> Assertions.fail("1 report missing"));

jvm.getAggregation(TwoRuntimeReport.class).ifPresentOrElse(
twoRuntimeReport -> Assertions.assertEquals(8.782d, twoRuntimeReport.getRuntimeDuration()),
twoRuntimeReport -> Assertions.assertEquals(8.772d, twoRuntimeReport.getRuntimeDuration()),
() -> Assertions.fail("2 report missing"));
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
public class PreunifiedJavaVirtualMachineConfigurationTest {

private String logFile = "preunified/g1gc/details/tenuring/180/g1gc.log";
private int[] times = { 0, 1028, 945481, 945481};
private int[] times = { 0, 1028, 945481, 944453};

@Tag("modulePath")
@Test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
public class UnifiedJavaVirtualMachineConfigurationTest {

private String logFile = "rolling/jdk14/rollinglogs/long_restart.log";
private int[][] times = { { 0, 13, 262172, 262172}, { 259077, 259077, 262172, 3095}};
private int[][] times = { { 0, 13, 262172, 262159}, { 259077, 259077, 262172, 3992}};

@Tag("modulePath")
@Test
Expand Down

0 comments on commit 7b67eae

Please sign in to comment.