arashja / hamcrest

Automatically exported from code.google.com/p/hamcrest
0 stars 0 forks source link

Date matcher #91

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago

Hi, here's a date matcher. Compares the Year, Month, and Day of Month of a
java.util.Date. Feel free to include it in hamcrest if you like.

The three booleans were used so that the it could output a message saying
which parts specifically did not match. I couldn't quite figure out how to
do it, but I left it in place so that someone else can use it. 

Original issue reported on code.google.com by haikal.s...@gmail.com on 25 Jun 2009 at 7:29

Attachments:

GoogleCodeExporter commented 8 years ago
A matcher must be immutable, so this implementation is incorrect.

Original comment by nat.pr...@gmail.com on 25 Jun 2009 at 4:51

GoogleCodeExporter commented 8 years ago
Ah, I was unaware of that. Is there a developer guide that walks you through 
Dos and
Don'ts?

Original comment by haikal.s...@gmail.com on 1 Jul 2009 at 5:45

GoogleCodeExporter commented 8 years ago
It's mentioned in the tutorial.  We should add it to the javadoc of the Matcher
interface.

Original comment by nat.pr...@gmail.com on 1 Jul 2009 at 9:16