Add unit tests for search ranking.