Fix warnings in test suite and gemspec
Merge pull request #3318 from rohit/fix-warnings

Fix warnings in test suite and gemspec