mirror of
https://github.com/espocrm/espocrm.git
synced 2026-06-28 23:16:03 +00:00
fix index defs
This commit is contained in:
@@ -74,7 +74,7 @@ class IndexDefs
|
||||
*/
|
||||
public function isUnique() : bool
|
||||
{
|
||||
$type = $this->data['tyoe'] ?? null;
|
||||
$type = $this->data['type'] ?? null;
|
||||
|
||||
return $type === 'unique';
|
||||
}
|
||||
|
||||
@@ -228,7 +228,7 @@ class DefsTest extends \PHPUnit\Framework\TestCase
|
||||
$this->defs->getEntity('Test')->getRelation('r1');
|
||||
}
|
||||
|
||||
public function getIndex1()
|
||||
public function testGetIndex1()
|
||||
{
|
||||
$data = [
|
||||
'Test' => [
|
||||
@@ -251,7 +251,7 @@ class DefsTest extends \PHPUnit\Framework\TestCase
|
||||
|
||||
$entityDefs = $this->defs->getEntity('Test');
|
||||
|
||||
$this->assertEquals(['i1', 'i2'], $entityDefs->getIndexList());
|
||||
$this->assertEquals(['i1', 'i2'], $entityDefs->getIndexNameList());
|
||||
|
||||
$this->assertEquals('i1', $entityDefs->getIndex('i1')->getName());
|
||||
|
||||
|
||||
Reference in New Issue
Block a user