Ronald Mos - 2012-12-30


Maybe this already was mentioned. I think there is a (small logical) error in lesson 12 (in the error text that is printed when an assert fails.
A piece of the testCheckOut method:

assertTrue("Book check in failed", ml.checkIn(b1));

assertFalse("Book was already checked in", ml.checkIn(b1));

In the first assert we expect the checkIn to return True (because checkin is succesful). If this would fail we would print a message like "book check in failed".
Now in the second assert we expect the checkIn to fail, because the book was checked in already in the first line. So we expect a checkIn to return a False.  If for some reason checkin returns a True (which we don't expect) than the message should never be "Book was already checked in", because the checkin was succesful!

The message to be printed should be something like: "Book was erroneous checked in for a second time"

Btw Thanx for the great course. It is helping me a lot.