Skip to content

Commit

Permalink
PK tests changed
Browse files Browse the repository at this point in the history
  • Loading branch information
SCIF committed Mar 3, 2018
1 parent ba9a0c1 commit c7a088b
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1407,7 +1407,7 @@ public function testAlterTableChangePrimaryKey() : void
$this->_sm->dropAndCreateTable($tableFrom);

$tableFrom = $this->_sm->listTableDetails('primary_key_userid');
self::assertTrue($tableFrom->getColumn('user_id')->getAutoincrement());
self::assertEquals(['user_id'], $tableFrom->getPrimaryKey()->getColumns());

$tableTo = new Table('primary_key_id');
$column = $tableTo->addColumn('id', 'integer');
Expand All @@ -1418,7 +1418,7 @@ public function testAlterTableChangePrimaryKey() : void
$diff = $c->diffTable($tableFrom, $tableTo);

$this->_sm->alterTable($diff);
$tableFinal = $this->_sm->listTableDetails('autoinc_type_modification');
self::assertTrue($tableFinal->getColumn('id')->getAutoincrement());
$tableFinal = $this->_sm->listTableDetails('primary_key_userid');
self::assertEquals(['id'], $tableFinal->getPrimaryKey()->getColumns());
}
}

0 comments on commit c7a088b

Please sign in to comment.