Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
100.00% covered (success)
100.00%
18 / 18
100.00% covered (success)
100.00%
3 / 3
CRAP
100.00% covered (success)
100.00%
1 / 1
phpbb_dbal_migration_fail
100.00% covered (success)
100.00%
18 / 18
100.00% covered (success)
100.00%
3 / 3
3
100.00% covered (success)
100.00%
1 / 1
 update_schema
100.00% covered (success)
100.00%
7 / 7
100.00% covered (success)
100.00%
1 / 1
1
 revert_schema
100.00% covered (success)
100.00%
7 / 7
100.00% covered (success)
100.00%
1 / 1
1
 update_data
100.00% covered (success)
100.00%
4 / 4
100.00% covered (success)
100.00%
1 / 1
1
1<?php
2/**
3*
4* This file is part of the phpBB Forum Software package.
5*
6* @copyright (c) phpBB Limited <https://www.phpbb.com>
7* @license GNU General Public License, version 2 (GPL-2.0)
8*
9* For full copyright and license information, please see
10* the docs/CREDITS.txt file.
11*
12*/
13
14class phpbb_dbal_migration_fail extends \phpbb\db\migration\migration
15{
16    function update_schema()
17    {
18        return array(
19            'add_columns' => array(
20                $this->table_prefix . 'config' => array(
21                    'test_column' => array('BOOL', 1),
22                ),
23            ),
24        );
25    }
26
27    function revert_schema()
28    {
29        return array(
30            'drop_columns' => array(
31                $this->table_prefix . 'config' => array(
32                    'test_column',
33                ),
34            ),
35        );
36    }
37
38    function update_data()
39    {
40        return array(
41            array('config.add', array('foobar3', true)),
42            array('config.update', array('does_not_exist', true)),
43        );
44    }
45}