Fix cross platform support

puppetlabs-ruby breaks on a number of OSes (Ubuntu 10, 12, EL 5, etc) with its current default settings. This is a large commit but it aims at cleaning some of that up, along with some minor linter problems and updating the rspec tests to match the new logic.