Make some search test failures more informative.
Rationalise how we store/access search config.

  * Pull out the search configuration (connection settings and index
    names) into a separate class. This means we can access it from the
    app and also from the new Rakefile.
  * Pull the default search index setting into the Sinatra app only:
    it doesn't need to be a config-level setting, since Rake tasks are
    not going to need it and it's a legacy feature anyway.
  * Improve the way we override schema settings in tests. Instead of
    the tests having to know where to get the schema from and what to
    stub with the new version, we can specify that in a helper method
    in the superclass.

There's more work we could do to make the handling of index and
mapping settings more elegant and modular, but this is enough of an
improvement for the Rakefile work we have to do.