commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gary Gregory <garydgreg...@gmail.com>
Subject [lang] Better Validate.isInstance messages
Date Wed, 07 Sep 2011 18:26:51 GMT
Hi All:

The message for the exception thrown by Validate.isInstance does not mention
the actual type, only the expected type.

Is there any objection to changing this?

trunk: "The validated object is not an instance of %s"

Proposal (1): "The validated object is expected to be an instance of %s, not
a %s"

Or more succinctly (2): "Expected an instance of %s, got a %"

Or more succinctly (3), a la JUnit: "Expected: %s, actual: %"

Thoughts?

Gary


-- 
E-Mail: garydgregory@gmail.com | ggregory@apache.org
JUnit in Action, 2nd Ed: http://s.apache.org/rl
Spring Batch in Action: http://s.apache.org/HOq
Blog: http://garygregory.wordpress.com
Home: http://garygregory.com/
Tweet! http://twitter.com/GaryGregory

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message