(maint) Cleanup whitespace errors
Clean up some trailing whitespace.
(#22233) Remove filters for the tests

Without this patch an example is excluded entirely if the `json` library
is not available.  If it is available then a related example is removed
instead.  This is a problem because it isn't clear why the examples are
being removed when the tests are run.

This patch addresses the problem by marking the first test as pending if
the json library is not available.  The second test always runs with
this patch applied because the patch mocks the behavior of JSON being
absent even if it is present during the test.
(#22233) Replace expect().to with .should

Without this patch we're seeing test failures on the Solaris 10 spec
system.  These failures are caused by the system not respecting the
dependencies specified in the Gemfile.  This patch addresses the problem
by changing the tests to use rspec 2.9 compatible syntax since this is a
faster route to a green build than changing the spec system itself.

This patch will be reverted once the Solaris 10 spec system has been
updated to respect the Gemfile.
Merge branch '22233_cleanup'

* 22233_cleanup:
  (#22233) Replace expect().to with .should
  (#22233) Remove filters for the tests
  (maint) Cleanup whitespace errors Clean up some trailing whitespace.