Refactor getRegistrants and test