fix search spec

search spec failed when using rails4
Merge pull request #1296 from digineo/fix_search_test

fix search spec