_query = new Solarium_Query_Suggester; $this->_builder = new Solarium_Client_RequestBuilder_Suggester; } public function testBuildParams() { $this->_query->setCollate(true); $this->_query->setCount(13); $this->_query->setDictionary('suggest'); $this->_query->setQuery('ap ip'); $this->_query->setOnlyMorePopular(true); $request = $this->_builder->build($this->_query); $this->assertEquals( array( 'spellcheck' => 'true', 'q' => 'ap ip', 'spellcheck.dictionary' => 'suggest', 'spellcheck.count' => 13, 'spellcheck.onlyMorePopular' => 'true', 'spellcheck.collate' => 'true', 'wt' => 'json', ), $request->getParams() ); $this->assertEquals( Solarium_Client_Request::METHOD_GET, $request->getMethod() ); } }