Fix test warnings

I was getting deprecation warnings and "already initialized constant" warnings when running rspec. These changes should fix those warnings.