Implemented objectAfterConstraint and its test. Added asserts.