|
@@ 212-220 (lines=9) @@
|
| 209 |
|
self::assertEquals($expected, Comparator::compareSchemas($schema1, $schema2)); |
| 210 |
|
} |
| 211 |
|
|
| 212 |
|
public function testCompareChangedColumnsChangeType() |
| 213 |
|
{ |
| 214 |
|
$column1 = new Column('charfield1', Type::getType('string')); |
| 215 |
|
$column2 = new Column('charfield1', Type::getType('integer')); |
| 216 |
|
|
| 217 |
|
$c = new Comparator(); |
| 218 |
|
self::assertEquals(array('type'), $c->diffColumn($column1, $column2)); |
| 219 |
|
self::assertEquals(array(), $c->diffColumn($column1, $column1)); |
| 220 |
|
} |
| 221 |
|
|
| 222 |
|
public function testCompareChangedColumnsChangeCustomSchemaOption() |
| 223 |
|
{ |
|
@@ 882-891 (lines=10) @@
|
| 879 |
|
/** |
| 880 |
|
* @group DBAL-106 |
| 881 |
|
*/ |
| 882 |
|
public function testDiffDecimalWithNullPrecision() |
| 883 |
|
{ |
| 884 |
|
$column = new Column('foo', Type::getType('decimal')); |
| 885 |
|
$column->setPrecision(null); |
| 886 |
|
|
| 887 |
|
$column2 = new Column('foo', Type::getType('decimal')); |
| 888 |
|
|
| 889 |
|
$c = new Comparator(); |
| 890 |
|
self::assertEquals(array(), $c->diffColumn($column, $column2)); |
| 891 |
|
} |
| 892 |
|
|
| 893 |
|
/** |
| 894 |
|
* @group DBAL-204 |