Minor improvements to unit testing

Resolves: https://www.pivotaltracker.com/story/show/59352034