Examples of BenchmarkOptions


Examples of com.carrotsearch.junitbenchmarks.BenchmarkOptions

           
            boolean hit = false;
           
            for (Annotation a : annotations) {
                if (a.annotationType().equals(BenchmarkOptions.class)) {
                    final BenchmarkOptions old = (BenchmarkOptions)a;
                    BenchmarkOptions replacement = getWrappedBenchmarkOptions(old, rounds);
                    modifiedAnnotations.add(replacement);
                    log.debug("Modified BenchmarkOptions annotation on {}", mname);
                    hit = true;
                } else {
                    modifiedAnnotations.add(a);
                    log.debug("Kept annotation {} with annotation type {} on {}",
                            new Object[] { a, a.annotationType(), mname });
                }
            }
           
            if (!hit) {
                BenchmarkOptions opts = getDefaultBenchmarkOptions(rounds);
                modifiedAnnotations.add(opts);
                log.debug("Added BenchmarkOptions {} with annotation type {} to {}",
                        new Object[] { opts, opts.annotationType(), mname });
            }
           
            Description roundsAdjustedDesc =
                    Description.createTestDescription(
                            clazz, mname,
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.