public function testWhere() { $criteria = new \Reach\Sphinx\Criteria(['limit' => 2]); $query = \Model\Sphinx\TestIndex::query($criteria); $this->assertInstanceOf('\\Reach\\Sphinx\\Query', $query); $resultSet = $query->comment('test')->search('game')->addBetween('viewCount', 1, 1000)->all(); $this->assertInstanceOf('\\Reach\\Sphinx\\ResultSet', $resultSet); $this->assertEquals(2, $resultSet->count()); }
public function testConnection() { $connection = \Model\Sphinx\TestIndex::getConnection(); $this->assertInstanceOf('\\Reach\\Sphinx\\Connection', $connection); }