Fix unit tests that were failing against server version 2.5.2.
Changes suggested in the code review.
Fixed if statements against version number.