Fix Tempfile.create in Ruby 2.1+ by adding Dir::Tmpname

Tempfile requires Dir::Tmpname in Ruby 2.1+ (Possibly in 2.0 as well, I haven't tested it). I added the MRI implementation, and a test.

I also fixed a couple of test bugs/deprecations that I ran across in 2.1