Working version with unit test changes

Also includes new department column in userProfile table.