### Question:
NoOp implements NullaryProcedure, Procedure<Object>, BinaryProcedure<Object, Object> { @Override public boolean equals(Object that) { return (that instanceof NoOp); } NoOp(); void run(); void run(Object obj); void run(Object left, Object right); @Override boolean equals(Object that); @Override int hashCode(); @Override String toString(); static NoOp instance(); @SuppressWarnings("unchecked") static Procedure<A> unaryInstance(); @SuppressWarnings("unchecked") static BinaryProcedure<L, R> binaryInstance(); static final NoOp INSTANCE; }### Answer:
@Test public void testEquals() throws Exception { NoOp p = new NoOp(); assertEquals(p,p); assertObjectsAreEqual(p,new NoOp()); assertObjectsAreEqual(p,NoOp.instance()); assertObjectsAreNotEqual(p,new NullaryProcedure() { public void run() { } }); assertObjectsAreNotEqual(p,new Procedure<Object>() { public void run(Object a) { } }); assertObjectsAreNotEqual(p,new BinaryProcedure<Object, Object>() { public void run(Object a, Object b) { } }); }