### Question:
Capsule implements Runnable, InvocationHandler { protected static final int compareVersions(String a, String b, int n) { return compareVersions(parseJavaVersion(a), parseJavaVersion(b), n); } @SuppressWarnings({"OverridableMethodCallInConstructor", "LeakingThisInConstructor"}) protected  Capsule(Path jarFile); @SuppressWarnings("LeakingThisInConstructor") protected  Capsule(Capsule pred); static final void main(String[] args); @SuppressWarnings({"BroadCatchBlock", "UnusedAssignment"}) static int main0(String[] args0); static void premain(String agentArgs, Instrumentation inst); static Object getCapsule(String capletClassName); boolean isAgent(); @Override final void run(); @Override Object invoke(Object proxy, Method method, Object[] args); @Override final int hashCode(); @Override final boolean equals(Object obj); @Override String toString(); static final String VERSION; }### Answer:
@Test public void testCompareVersions() { assertTrue(Capsule.compareVersions("1.8.0_30-ea", "1.8.0_30") < 0); assertTrue(Capsule.compareVersions("1.8.0_30-ea", "1.8.0_20") > 0); assertTrue(Capsule.compareVersions("1.8.0-ea", "1.8.0_20") < 0); assertTrue(Capsule.compareVersions("1.8.0-ea", "1.8.0") < 0); assertTrue(Capsule.compareVersions("1.8.0-ea", "1.7.0") > 0); }