Add missing tests

Improve coverage for candidates.
Merge pull request #578 from xymbol/candidates-tests

Add missing tests