_query = new Solarium_Query_Terms; } public function testGetType() { $this->assertEquals(Solarium_Client::QUERYTYPE_TERMS, $this->_query->getType()); } public function testSetAndGetFields() { $this->_query->setFields('fieldA,fieldB'); $this->assertEquals('fieldA,fieldB', $this->_query->getFields()); } public function testSetAndGetLowerbound() { $this->_query->setLowerbound('f'); $this->assertEquals('f', $this->_query->getLowerbound()); } public function testSetAndGetLowerboundInclude() { $this->_query->setLowerboundInclude(true); $this->assertEquals(true, $this->_query->getLowerboundInclude()); } public function testSetAndGetMinCount() { $this->_query->setMinCount(3); $this->assertEquals(3, $this->_query->getMinCount()); } public function testSetAndGetMaxCount() { $this->_query->setMaxCount(25); $this->assertEquals(25, $this->_query->getMaxCount()); } public function testSetAndGetPrefix() { $this->_query->setPrefix('wat'); $this->assertEquals('wat', $this->_query->getPrefix()); } public function testSetAndGetRegex() { $this->_query->setRegex('at.*'); $this->assertEquals('at.*', $this->_query->getRegex()); } public function testSetAndGetRegexFlags() { $this->_query->setRegexFlags('case_insensitive,comments'); $this->assertEquals('case_insensitive,comments', $this->_query->getRegexFlags()); } public function testSetAndGetLimit() { $this->_query->setLimit(15); $this->assertEquals(15, $this->_query->getLimit()); } public function testSetAndGetUpperbound() { $this->_query->setUpperbound('x'); $this->assertEquals('x', $this->_query->getUpperbound()); } public function testSetAndGetUpperboundInclude() { $this->_query->setUpperboundInclude(true); $this->assertEquals(true, $this->_query->getUpperboundInclude()); } public function testSetAndGetRaw() { $this->_query->setRaw(false); $this->assertEquals(false, $this->_query->getRaw()); } public function testSetAndGetSort() { $this->_query->setSort('index'); $this->assertEquals('index', $this->_query->getSort()); } }