public function setSelect($select) { if (!is_string($select)) { throw new \InvalidArgumentException('Select list must be a string.'); } $this->select = $select; return $this; }
public function testSetSelect() { $sphinx = new SphinxClient(); $sphinx->setSelect('*, @weight + 10 as myweight'); $this->assertSame($sphinx->select, '*, @weight + 10 as myweight'); }