mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-10 21:38:54 +00:00
[ticket/10247] Add a db_tools test for the removal of a primary key column.
The previous drop column test already deleted the primary key, so that one was replaced with an ordinary column. PHPBB3-10247
This commit is contained in:
parent
984fd07319
commit
96eab49a7a
1 changed files with 9 additions and 1 deletions
|
@ -241,6 +241,15 @@ class phpbb_dbal_db_tools_test extends phpbb_database_test_case
|
||||||
}
|
}
|
||||||
|
|
||||||
public function test_column_remove()
|
public function test_column_remove()
|
||||||
|
{
|
||||||
|
$this->assertTrue($this->tools->sql_column_exists('prefix_table_name', 'c_int_size'));
|
||||||
|
|
||||||
|
$this->assertTrue($this->tools->sql_column_remove('prefix_table_name', 'c_int_size'));
|
||||||
|
|
||||||
|
$this->assertFalse($this->tools->sql_column_exists('prefix_table_name', 'c_int_size'));
|
||||||
|
}
|
||||||
|
|
||||||
|
public function test_column_remove_primary()
|
||||||
{
|
{
|
||||||
$this->assertTrue($this->tools->sql_column_exists('prefix_table_name', 'c_id'));
|
$this->assertTrue($this->tools->sql_column_exists('prefix_table_name', 'c_id'));
|
||||||
|
|
||||||
|
@ -264,5 +273,4 @@ class phpbb_dbal_db_tools_test extends phpbb_database_test_case
|
||||||
|
|
||||||
$this->tools->sql_table_drop('prefix_test_table');
|
$this->tools->sql_table_drop('prefix_test_table');
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue