Stub out first unit test and do some other minor refactoring.