Skip to content

Instantly share code, notes, and snippets.

@Jotschi
Created June 14, 2016 11:02
Show Gist options
  • Select an option

  • Save Jotschi/bf1f50d0ee27cda1bbb71bdef38cc115 to your computer and use it in GitHub Desktop.

Select an option

Save Jotschi/bf1f50d0ee27cda1bbb71bdef38cc115 to your computer and use it in GitHub Desktop.
@Test
public void testCreatePerformance() {
// Warmup the system caches etc
warmup();
// Start the stopwatch
mark();
// Invoke the create node action 1000 times
for(int i = 0; i < 1000; i++) {
createNode();
}
// Stop the stopwatch and assert the duration
assertDuration(5000);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment