Fix tests that depended on the exact API output

Rather than asserting the whole body of the API response matches our
expectations we instead just check subsets of the body to see if
elements are visible/hidden appropriately.
Delete memberships from json docs before indexing

Due to memberships being stored in a different collection, we can't index
them in elasticsearch as embedded documents because they may change in
the database but the related record wouldn't be reindexed, so they would
fall out of sync.

In the future it might be worth making the list of fields to exclude
from the json configurable on a per-model basis, so the person model
could be configured to always hide memberships. This could possibly even
be inferred from the JSON schemas somehow.