8239265: JFR: Test cleanup of jdk.jfr.api.consumer package
Erik Gahlin
erik.gahlin at oracle.com
Mon Feb 17 20:36:28 UTC 2020
Hi,
Could I have review of a test cleanup of the jdk.jfr.api.consumer package.
Changes:
- Make test cases exhaustive.
- Add @summary where missing.
- Favor final fields over global variables.
- Refactor so sub test failures can be deduced from stack trace.
- Use try-with-resources.
- Remove unnecessary blank lines .
- Add space after cast.
- Initialize variables close to where they are first used.
- Remove redundant or misaligned logging.
- Use appropriate assert method.
- Put test logic in the main method.
- Reduce interval so tests runs faster.
- Move inner classes to the top.
- Simplify methods.
- Reduce logging to avoid output overflow.
- Add explanatory comments where needed.
Bug:
https://bugs.openjdk.java.net/browse/JDK-8239265
Webrev:
http://cr.openjdk.java.net/~egahlin/8239265/
/test/jdk/jdk/jfr/api/consumer
Thanks
Erik
More information about the hotspot-jfr-dev
mailing list