private Method getMethod(String name, Class<?>... parameterTypes) throws NoSuchMethodException {
return getClass().getDeclaredMethod(name, parameterTypes);
}
private void assertReferenceSerializable(Method method) throws Exception {
MethodHolder reference = MethodHolder.of(method);
Utils.deserialize(Utils.serialize(reference));
}