refactored out some usings and more tests