@@ -16,13 +16,13 @@ |
||
16 | 16 | |
17 | 17 | protected function setUp() |
18 | 18 | { |
19 | - if (! extension_loaded('oci8')) { |
|
19 | + if ( ! extension_loaded('oci8')) { |
|
20 | 20 | $this->markTestSkipped('oci8 is not installed.'); |
21 | 21 | } |
22 | 22 | |
23 | 23 | parent::setUp(); |
24 | 24 | |
25 | - if (! $this->_conn->getDriver() instanceof Driver) { |
|
25 | + if ( ! $this->_conn->getDriver() instanceof Driver) { |
|
26 | 26 | $this->markTestSkipped('oci8 only test.'); |
27 | 27 | } |
28 | 28 |
@@ -10,13 +10,13 @@ |
||
10 | 10 | { |
11 | 11 | protected function setUp() |
12 | 12 | { |
13 | - if (! extension_loaded('oci8')) { |
|
13 | + if ( ! extension_loaded('oci8')) { |
|
14 | 14 | $this->markTestSkipped('oci8 is not installed.'); |
15 | 15 | } |
16 | 16 | |
17 | 17 | parent::setUp(); |
18 | 18 | |
19 | - if (! $this->_conn->getDriver() instanceof Driver) { |
|
19 | + if ( ! $this->_conn->getDriver() instanceof Driver) { |
|
20 | 20 | $this->markTestSkipped('oci8 only test.'); |
21 | 21 | } |
22 | 22 | } |
@@ -10,13 +10,13 @@ |
||
10 | 10 | { |
11 | 11 | protected function setUp() |
12 | 12 | { |
13 | - if (! extension_loaded('mysqli')) { |
|
13 | + if ( ! extension_loaded('mysqli')) { |
|
14 | 14 | $this->markTestSkipped('mysqli is not installed.'); |
15 | 15 | } |
16 | 16 | |
17 | 17 | parent::setUp(); |
18 | 18 | |
19 | - if (! $this->_conn->getDriver() instanceof Driver) { |
|
19 | + if ( ! $this->_conn->getDriver() instanceof Driver) { |
|
20 | 20 | $this->markTestSkipped('MySQLi only test.'); |
21 | 21 | } |
22 | 22 | } |
@@ -6,13 +6,13 @@ |
||
6 | 6 | { |
7 | 7 | protected function setUp() |
8 | 8 | { |
9 | - if (!extension_loaded('mysqli')) { |
|
9 | + if ( ! extension_loaded('mysqli')) { |
|
10 | 10 | $this->markTestSkipped('mysqli is not installed.'); |
11 | 11 | } |
12 | 12 | |
13 | 13 | parent::setUp(); |
14 | 14 | |
15 | - if ( !($this->_conn->getDriver() instanceof \Doctrine\DBAL\Driver\Mysqli\Driver)) { |
|
15 | + if ( ! ($this->_conn->getDriver() instanceof \Doctrine\DBAL\Driver\Mysqli\Driver)) { |
|
16 | 16 | $this->markTestSkipped('MySQLi only test.'); |
17 | 17 | } |
18 | 18 | } |
@@ -10,13 +10,13 @@ |
||
10 | 10 | { |
11 | 11 | protected function setUp() |
12 | 12 | { |
13 | - if (! extension_loaded('PDO_OCI')) { |
|
13 | + if ( ! extension_loaded('PDO_OCI')) { |
|
14 | 14 | $this->markTestSkipped('PDO_OCI is not installed.'); |
15 | 15 | } |
16 | 16 | |
17 | 17 | parent::setUp(); |
18 | 18 | |
19 | - if (! $this->_conn->getDriver() instanceof Driver) { |
|
19 | + if ( ! $this->_conn->getDriver() instanceof Driver) { |
|
20 | 20 | $this->markTestSkipped('PDO_OCI only test.'); |
21 | 21 | } |
22 | 22 | } |
@@ -38,7 +38,7 @@ |
||
38 | 38 | $sm->createTable($table); |
39 | 39 | |
40 | 40 | |
41 | - } catch(\Exception $e) { |
|
41 | + } catch (\Exception $e) { |
|
42 | 42 | } |
43 | 43 | |
44 | 44 | $this->_conn->executeUpdate('DELETE FROM master_slave_table'); |
@@ -22,7 +22,7 @@ discard block |
||
22 | 22 | $table->setPrimaryKey(array('id')); |
23 | 23 | |
24 | 24 | $this->_conn->getSchemaManager()->createTable($table); |
25 | - } catch(\Exception $e) { |
|
25 | + } catch (\Exception $e) { |
|
26 | 26 | |
27 | 27 | } |
28 | 28 | $this->_conn->executeUpdate('DELETE FROM write_table'); |
@@ -161,7 +161,7 @@ discard block |
||
161 | 161 | $sequence = new \Doctrine\DBAL\Schema\Sequence('write_table_id_seq'); |
162 | 162 | try { |
163 | 163 | $this->_conn->getSchemaManager()->createSequence($sequence); |
164 | - } catch(\Exception $e) { |
|
164 | + } catch (\Exception $e) { |
|
165 | 165 | } |
166 | 166 | |
167 | 167 | $sequences = $this->_conn->getSchemaManager()->listSequences(); |
@@ -184,7 +184,7 @@ discard block |
||
184 | 184 | $this->markTestSkipped("Test only works consistently on platforms that support sequences and don't support identity columns."); |
185 | 185 | } |
186 | 186 | |
187 | - self::assertFalse($this->_conn->lastInsertId( null )); |
|
187 | + self::assertFalse($this->_conn->lastInsertId(null)); |
|
188 | 188 | |
189 | 189 | } |
190 | 190 | |
@@ -256,7 +256,7 @@ discard block |
||
256 | 256 | { |
257 | 257 | $platform = $this->_conn->getDatabasePlatform(); |
258 | 258 | |
259 | - if ( ! ($platform->supportsIdentityColumns() || $platform->usesSequenceEmulatedIdentityColumns()) ) { |
|
259 | + if ( ! ($platform->supportsIdentityColumns() || $platform->usesSequenceEmulatedIdentityColumns())) { |
|
260 | 260 | $this->markTestSkipped( |
261 | 261 | 'Test only works on platforms with identity columns or sequence emulated identity columns.' |
262 | 262 | ); |
@@ -268,7 +268,7 @@ discard block |
||
268 | 268 | |
269 | 269 | try { |
270 | 270 | $this->_conn->getSchemaManager()->dropTable($table->getQuotedName($platform)); |
271 | - } catch(\Exception $e) { } |
|
271 | + } catch (\Exception $e) { } |
|
272 | 272 | |
273 | 273 | foreach ($platform->getCreateTableSQL($table) as $sql) { |
274 | 274 | $this->_conn->exec($sql); |
@@ -19,7 +19,7 @@ discard block |
||
19 | 19 | { |
20 | 20 | parent::setUp(); |
21 | 21 | |
22 | - if ( !($this->_conn->getDriver() instanceof ExceptionConverterDriver)) { |
|
22 | + if ( ! ($this->_conn->getDriver() instanceof ExceptionConverterDriver)) { |
|
23 | 23 | $this->markTestSkipped('Driver does not support special exception handling.'); |
24 | 24 | } |
25 | 25 | } |
@@ -164,7 +164,7 @@ discard block |
||
164 | 164 | { |
165 | 165 | $platform = $this->_conn->getDatabasePlatform(); |
166 | 166 | |
167 | - if (!$platform->supportsForeignKeyConstraints()) { |
|
167 | + if ( ! $platform->supportsForeignKeyConstraints()) { |
|
168 | 168 | $this->markTestSkipped("Only fails on platforms with foreign key constraints."); |
169 | 169 | } |
170 | 170 | |
@@ -286,7 +286,7 @@ discard block |
||
286 | 286 | $this->markTestSkipped("Only fails this way on sqlite"); |
287 | 287 | } |
288 | 288 | |
289 | - $filename = sprintf('%s/%s', sys_get_temp_dir(), 'doctrine_failed_connection_'.$mode.'.db'); |
|
289 | + $filename = sprintf('%s/%s', sys_get_temp_dir(), 'doctrine_failed_connection_' . $mode . '.db'); |
|
290 | 290 | |
291 | 291 | if (file_exists($filename)) { |
292 | 292 | chmod($filename, 0200); // make the file writable again, so it can be removed on Windows |
@@ -14,7 +14,7 @@ |
||
14 | 14 | parent::setUp(); |
15 | 15 | |
16 | 16 | $platform = $this->_conn->getDatabasePlatform()->getName(); |
17 | - if (!in_array($platform, array('mysql', 'sqlite'))) { |
|
17 | + if ( ! in_array($platform, array('mysql', 'sqlite'))) { |
|
18 | 18 | $this->markTestSkipped('Currently restricted to MySQL and SQLite.'); |
19 | 19 | } |
20 | 20 | } |