Don't add a filter if not needed

This skips adding the filter if searching a single index containings exactly
the same number of namespaces that the user is searching.  This will provide
a marginal improvement on the most common case: searching the main namespace.
It might provide other improvements along the way, but the main namespace
one is the most important because it is so much more common.

Also remove a flaky test case the complains for no reason about almost every
commit even though the feature works.  Useless.

Change-Id: I7a8be3bb2dae9753ddff6bf4b7c15fbc2596cd20
Merge "Don't add a filter if not needed"