checkSequenceRenaming example

$this->assertIndexOnColumns($table_name['id'], 'primary');
    $this->assertIndexOnColumns($table_name['test_field'], 'unique');

    $new_table_name = strtolower($this->getRandomGenerator()->name(63 - strlen($this->getDatabasePrefix())));
    $this->assertNull($this->schema->renameTable($table_name$new_table_name));

    // Test for renamed primary and unique keys.     $this->assertIndexOnColumns($new_table_name['id'], 'primary');
    $this->assertIndexOnColumns($new_table_name['test_field'], 'unique');

    // Check that the ID sequence gets renamed when the table is renamed.     $this->checkSequenceRenaming($new_table_name);
  }

  /** * Tests creating a table with database specific data type. */
  abstract public function testTableWithSpecificDataType(): void;

  /** * Tests creating unsigned columns and data integrity thereof. */
  public function testUnsignedColumns(): void {
    
Home | Imprint | This part of the site doesn't use cookies.