tests/Doctrine/Tests/DBAL/Platforms/AbstractMySQLPlatformTestCase.php 1 location
|
@@ 95-111 (lines=17) @@
|
| 92 |
|
self::assertEquals('DROP TABLE foobar', $this->platform->getDropTableSQL('foobar')); |
| 93 |
|
} |
| 94 |
|
|
| 95 |
|
public function testGeneratesTypeDeclarationForIntegers() : void |
| 96 |
|
{ |
| 97 |
|
self::assertEquals( |
| 98 |
|
'INT', |
| 99 |
|
$this->platform->getIntegerTypeDeclarationSQL([]) |
| 100 |
|
); |
| 101 |
|
self::assertEquals( |
| 102 |
|
'INT AUTO_INCREMENT', |
| 103 |
|
$this->platform->getIntegerTypeDeclarationSQL(['autoincrement' => true]) |
| 104 |
|
); |
| 105 |
|
self::assertEquals( |
| 106 |
|
'INT AUTO_INCREMENT', |
| 107 |
|
$this->platform->getIntegerTypeDeclarationSQL( |
| 108 |
|
['autoincrement' => true, 'primary' => true] |
| 109 |
|
) |
| 110 |
|
); |
| 111 |
|
} |
| 112 |
|
|
| 113 |
|
public function testPrefersIdentityColumns() : void |
| 114 |
|
{ |
tests/Doctrine/Tests/DBAL/Platforms/AbstractPostgreSqlPlatformTestCase.php 1 location
|
@@ 250-266 (lines=17) @@
|
| 247 |
|
self::assertSame('', $sql); |
| 248 |
|
} |
| 249 |
|
|
| 250 |
|
public function testGeneratesTypeDeclarationForIntegers() : void |
| 251 |
|
{ |
| 252 |
|
self::assertEquals( |
| 253 |
|
'INT', |
| 254 |
|
$this->platform->getIntegerTypeDeclarationSQL([]) |
| 255 |
|
); |
| 256 |
|
self::assertEquals( |
| 257 |
|
'SERIAL', |
| 258 |
|
$this->platform->getIntegerTypeDeclarationSQL(['autoincrement' => true]) |
| 259 |
|
); |
| 260 |
|
self::assertEquals( |
| 261 |
|
'SERIAL', |
| 262 |
|
$this->platform->getIntegerTypeDeclarationSQL( |
| 263 |
|
['autoincrement' => true, 'primary' => true] |
| 264 |
|
) |
| 265 |
|
); |
| 266 |
|
} |
| 267 |
|
|
| 268 |
|
public function getGenerateUniqueIndexSql() : string |
| 269 |
|
{ |
tests/Doctrine/Tests/DBAL/Platforms/AbstractSQLServerPlatformTestCase.php 1 location
|
@@ 107-123 (lines=17) @@
|
| 104 |
|
self::assertEquals('DROP TABLE foobar', $this->platform->getDropTableSQL('foobar')); |
| 105 |
|
} |
| 106 |
|
|
| 107 |
|
public function testGeneratesTypeDeclarationForIntegers() : void |
| 108 |
|
{ |
| 109 |
|
self::assertEquals( |
| 110 |
|
'INT', |
| 111 |
|
$this->platform->getIntegerTypeDeclarationSQL([]) |
| 112 |
|
); |
| 113 |
|
self::assertEquals( |
| 114 |
|
'INT IDENTITY', |
| 115 |
|
$this->platform->getIntegerTypeDeclarationSQL(['autoincrement' => true]) |
| 116 |
|
); |
| 117 |
|
self::assertEquals( |
| 118 |
|
'INT IDENTITY', |
| 119 |
|
$this->platform->getIntegerTypeDeclarationSQL( |
| 120 |
|
['autoincrement' => true, 'primary' => true] |
| 121 |
|
) |
| 122 |
|
); |
| 123 |
|
} |
| 124 |
|
|
| 125 |
|
public function testGeneratesTypeDeclarationsForStrings() : void |
| 126 |
|
{ |