### Question:
ProcedureFunction implements Function<A, T> { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof ProcedureFunction<?, ?>)) { return false; } ProcedureFunction<?, ?> that = (ProcedureFunction<?, ?>) obj; return this.procedure.equals(that.procedure); } ProcedureFunction(Procedure<? super A> procedure); T evaluate(A obj); @Override boolean equals(Object obj); @Override int hashCode(); @Override String toString(); static ProcedureFunction<A, T> adapt(Procedure<? super A> procedure);  }### Answer:
@Test public void testEquals() throws Exception { Function<Object, Object> f = new ProcedureFunction<Object, Object>(NoOp.INSTANCE); assertEquals(f,f); assertObjectsAreEqual(f,new ProcedureFunction<Object, Object>(NoOp.INSTANCE)); assertObjectsAreNotEqual(f,Constant.of("x")); assertObjectsAreNotEqual(f, new ProcedureFunction<Object, Object>(new Procedure<Object>() { public void run(Object a) { } })); assertObjectsAreNotEqual(f,Constant.of(null)); assertTrue(!f.equals(null)); }