Inheritance: extends Doctrine\DBAL\Platforms\AbstractPlatform
Example #1
0
 /**
  * @group DBAL-944
  *
  * @dataProvider getGeneratesAlterColumnSQL
  */
 public function testGeneratesAlterColumnSQL($changedProperty, Column $column, $expectedSQLClause = null)
 {
     $tableDiff = new TableDiff('foo');
     $tableDiff->fromTable = new Table('foo');
     $tableDiff->changedColumns['bar'] = new ColumnDiff('bar', $column, array($changedProperty));
     $expectedSQL = array();
     if (null !== $expectedSQLClause) {
         $expectedSQL[] = 'ALTER TABLE foo ALTER COLUMN bar ' . $expectedSQLClause;
     }
     $expectedSQL[] = "CALL SYSPROC.ADMIN_CMD ('REORG TABLE foo')";
     $this->assertSame($expectedSQL, $this->_platform->getAlterTableSQL($tableDiff));
 }