New answers tagged


The first thing I noticed. The calendar in the constructor. If you wanted to test this class it would be really difficult because you are dependent on the Calendar implementation, and you have no control over the value it will return. It would be better to inject the calendar in to the constructor, or Abstract the desired functionality in to an interface and ...

Top 50 recent answers are included