Bug 1041534 - Refactor search tests to remove some code duplication. r=MattN