### Question:
BoundNullaryProcedure implements NullaryProcedure { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof BoundNullaryProcedure)) { return false; } BoundNullaryProcedure that = (BoundNullaryProcedure) obj; return procedure.equals(that.procedure) && (null == param ? null == that.param : param.equals(that.param)); } @SuppressWarnings("unchecked") <A> BoundNullaryProcedure(Procedure<? super A> procedure, A arg); void run(); @Override boolean equals(Object obj); @Override int hashCode(); @Override String toString(); static BoundNullaryProcedure bind(Procedure<? super A> procedure, A arg);  }### Answer:
@Test public void testEquals() throws Exception { NullaryProcedure f = new BoundNullaryProcedure(NoOp.INSTANCE,"xyzzy"); assertEquals(f,f); assertObjectsAreEqual(f,new BoundNullaryProcedure(NoOp.INSTANCE,"xyzzy")); assertObjectsAreNotEqual(f,NoOp.INSTANCE); assertObjectsAreNotEqual(f,new BoundNullaryProcedure(NoOp.INSTANCE,"foo")); assertObjectsAreNotEqual(f,new BoundNullaryProcedure(new FunctionProcedure<Object>(Identity.INSTANCE),"xyzzy")); assertObjectsAreNotEqual(f,new BoundNullaryProcedure(NoOp.INSTANCE,null)); assertObjectsAreEqual(new BoundNullaryProcedure(NoOp.INSTANCE,null),new BoundNullaryProcedure(NoOp.INSTANCE,null)); assertTrue(!f.equals(null)); }