for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
declare(strict_types = 1);
namespace TBolier\RethinkQL\IntegrationTest\Operation;
use TBolier\RethinkQL\Response\ResponseInterface;
class IndexTest extends AbstractTableTest
{
/**
* @throws \Exception
*/
public function testIndexCreate()
$this->insertDocument(1);
$res = $this->r()
->table('tabletest')
->indexCreate('title')
->run();
$this->assertObStatus(['created' => 1], $res->getData());
}
public function testIndexDrop()
$this->r()
->indexDrop('title')
$this->assertObStatus(['dropped' => 1], $res->getData());
public function testIndexList()
/** @var ResponseInterface $res */
->indexList()
$this->assertEquals('title', $res->getData()[0]);
public function testIndexRename()
->indexRename('title', 'description')
$this->assertObStatus(['renamed' => 1], $res->getData());
$this->assertEquals('description', $res->getData()[0]);