Added tests to render helper that expect `render partial: @foo` to
automatically call @foo.to_partial_path

Calling `render @foo` allows local variables but not options to be
passed to the partial renderer. The correct way to render an object AND
pass options to the partial renderer is to pass the object in the
`:partial` parameter. However, there were previously no tests for this
behaviour (in `render_helper_test.rb` at least).
Merge pull request #13761 from iainbeeston/refactor_out_render_object

Refactored object rendering in RenderingHelper#render into it's own method
`execute` is a hotspot, so let's reduce branches
Terminate the backend ourselves on PG 9.2+

This should make it harder to accidentally break this test.
Merge pull request #14035 from matthewd/pg_terminate_backend

Terminate the backend ourselves on PG 9.2+
Coerce strings when reading attributes.