leakcanary icon indicating copy to clipboard operation
leakcanary copied to clipboard

LeakCanary for JVM tests

Open pyricau opened this issue 3 years ago • 0 comments

When running JVM tests, it'd be nice to be able to use LeakAssertions.assertNoLeaks() and the associated junit test rule. Currently they're implemented in a way that can only run on an Android device, but it should be easy enough to adapt to a JVM.

One key question is whether this should be a single artifact that loads different code at runtime based on the env, or a different artifact. The general API shape and configuration points is likely to be very similar.

Here's an example implementation: https://github.com/cashapp/paparazzi/pull/431

pyricau avatar May 26 '22 19:05 pyricau