Commit 427d5b09 authored by Vincent Petry's avatar Vincent Petry Committed by Thomas Müller

Add test for column deletion migration

parent d7218f01
......@@ -234,6 +234,33 @@ class MigratorTest extends \Test\TestCase {
public function testDeletingColumn() {
$schema = new Schema([], [], $this->getSchemaConfig());
$table = $schema->createTable($this->tableName);
$table->addColumn('id', 'integer');
$table->addColumn('name', 'string');
$table->addColumn('to_delete', 'string');
$migrator = $this->manager->getMigrator();
$schemaManager = $this->connection->getSchemaManager();
$actualSchema = $schemaManager->createSchema();
// Oracle might change casing if double quotes were missing, so verify
// that the column names still match
$table = $actualSchema->getTable($this->tableName);
$this->assertEquals('id', $table->getColumn('id')->getName());
$this->assertEquals('name', $table->getColumn('name')->getName());
public function testReservedKeywords() {
$startSchema = new Schema([], [], $this->getSchemaConfig());
$table = $startSchema->createTable($this->tableName);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment