@@ 573-587 (lines=15) @@ | ||
570 | /** |
|
571 | * @group 2859 |
|
572 | */ |
|
573 | public function testGetDefaultValueDeclarationSQLForDateType() : void |
|
574 | { |
|
575 | $currentDateSql = $this->_platform->getCurrentDateSQL(); |
|
576 | foreach (['date', 'date_immutable'] as $type) { |
|
577 | $field = [ |
|
578 | 'type' => Type::getType($type), |
|
579 | 'default' => $currentDateSql, |
|
580 | ]; |
|
581 | ||
582 | self::assertSame( |
|
583 | ' DEFAULT ' . $currentDateSql, |
|
584 | $this->_platform->getDefaultValueDeclarationSQL($field) |
|
585 | ); |
|
586 | } |
|
587 | } |
|
588 | ||
589 | /** |
|
590 | * @group DBAL-45 |
@@ 1429-1443 (lines=15) @@ | ||
1426 | /** |
|
1427 | * @group 2859 |
|
1428 | */ |
|
1429 | public function testGetDefaultValueDeclarationSQLForDateType() : void |
|
1430 | { |
|
1431 | $currentDateSql = $this->_platform->getCurrentDateSQL(); |
|
1432 | foreach (['date', 'date_immutable'] as $type) { |
|
1433 | $field = [ |
|
1434 | 'type' => Type::getType($type), |
|
1435 | 'default' => $currentDateSql, |
|
1436 | ]; |
|
1437 | ||
1438 | self::assertSame( |
|
1439 | " DEFAULT '" . $currentDateSql . "'", |
|
1440 | $this->_platform->getDefaultValueDeclarationSQL($field) |
|
1441 | ); |
|
1442 | } |
|
1443 | } |
|
1444 | } |
|
1445 |