### Question:
LazyModel implements IModel<T>, IObjectClassAwareModel<T>,
		IObjectTypeAwareModel<T>, IPropertyReflectionAwareModel<T> { @Override public void detach() { if (target instanceof IDetachable) { ((IDetachable) target).detach(); } if (stack instanceof IDetachable) { ((IDetachable) stack).detach(); } if (stack instanceof Object[]) { for (Object object : (Object[]) stack) { if (object instanceof IDetachable) { ((IDetachable) object).detach(); } } } } LazyModel(Object target, Object stack); IModel<T> loadableDetachable(); @Override Class<T> getObjectClass(); Type getObjectType(); @Override Field getPropertyField(); @Override Method getPropertyGetter(); @Override Method getPropertySetter(); @Override void detach(); T getObject(); void setObject(T result); Object getTarget(); LazyModel<T> bind(Object target); @Override String toString(); String getPath(); static T from(T target); static T from(Class<T> targetType); static T from(IModel<T> target, Class<T> type); static T from(IModel<T> target); static LazyModel<R> model(R result); static String path(R result); static IMethodResolver methodResolver; }### Answer:
@Test public void detach() { final boolean[] detached = { false }; IModel<A> target = new IModel<A>() { @Override public A getObject() { return null; } @Override public void setObject(A a) { } @Override public void detach() { detached[0] = true; } }; LazyModel<A> model = model(from(target)); model.detach(); assertTrue(detached[0]); }