mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-18 14:31:19 +02:00
[ticket/11880] Break up schema changes in the migrator
PHPBB3-11880
This commit is contained in:
33
tests/dbal/migration/schema.php
Normal file
33
tests/dbal/migration/schema.php
Normal file
@@ -0,0 +1,33 @@
|
||||
<?php
|
||||
/**
|
||||
*
|
||||
* @package testing
|
||||
* @copyright (c) 2014 phpBB Group
|
||||
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
|
||||
*
|
||||
*/
|
||||
|
||||
class phpbb_dbal_migration_schema extends \phpbb\db\migration\migration
|
||||
{
|
||||
function update_schema()
|
||||
{
|
||||
return array(
|
||||
'add_columns' => array(
|
||||
$this->table_prefix . 'config' => array(
|
||||
'test_column1' => array('BOOL', 1),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
function revert_schema()
|
||||
{
|
||||
return array(
|
||||
'drop_columns' => array(
|
||||
$this->table_prefix . 'config' => array(
|
||||
'test_column1',
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user