Skip to content

A set of framework and utils to test performances and report differences among snapshots.

Notifications You must be signed in to change notification settings

Kellindil/fr.obeo.performance

 
 

Repository files navigation

fr.obeo.performance

A simple Java library to record performance data when running tests.

Inspired by Eclipse’s org.eclipse.test.performance, but this is simpler and produces an EMF model for the results instead of storing them inside a relation DB.

Basic usage:

// Create a global PerformanceTestSuite object
PerformanceTestSuite suite = new PerformanceTestSuite("My test suite");
// For each individual test, create a monitor
PerformanceMonitor monitor = suite.createMonitor("Scenario #1");
// Execute the code to test inside monitor.start()/monitor.stop(). 
// You can do multiple iterations, which will be saved as individual data
// points.
for (int i = 0; i < ITERATIONS; i++) {
    monitor.start();
    doSomething();
    monitor.stop();
}
// This marks the end of the scenario
monitor.commit();
// Alternatively, you can use:
monitor.measure(ITERATIONS, new Runnable() {
  public void run() {
    doSomething();
  }
};
// Repeat with other monitors if you have more scenarios
// Finally save the result:
suite.save(URI.createFileURI("/tmp/test.performance"));

Dependencies

  • EMF (but not Eclipse)

License

Copyright © 2011 Obeo. All rights reserved. This program and the accompanying materials are made available under the terms of the Eclipse Public License v1.0 which accompanies this distribution, and is available at http://www.eclipse.org/legal/epl-v10.html

About

A set of framework and utils to test performances and report differences among snapshots.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Java 100.0%