Fix calls to Tempfile.new (GH issue #792)

Suffix of "*.rb" caused temp files to be named with "*.rb"
at the end, literally.  Not all file systems like that, and
it's almost certainly not what was intended.
Merge pull request #796 from L2G/gh-792

Fix calls to Tempfile.new (GH issue #792)
Remove legacy methods from helpers

From BaseHelpers:

  * #stub_proc
  * #create_command_stub

From CommandHelpers:

  * #retrieve_code_object_from_string
  * #file_and_line_from_binding
  * #make_header

Signed-off-by: Kyrylo Silin <kyrylosilin@gmail.com>