Skip to content

Commit

Permalink
Fix PHPCS.
Browse files Browse the repository at this point in the history
  • Loading branch information
markstory committed Mar 6, 2015
1 parent 8b18ed2 commit 8c69ebf
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
4 changes: 2 additions & 2 deletions src/Database/Schema/PostgresSchema.php
Original file line number Diff line number Diff line change
Expand Up @@ -235,8 +235,8 @@ public function convertIndexDescription(Table $table, $row)
// If there is only one column in the primary key and it is integery,
// make it autoincrement.
$columnDef = $table->column($columns[0]);
if (
$type === Table::CONSTRAINT_PRIMARY &&

if ($type === Table::CONSTRAINT_PRIMARY &&
count($columns) === 1 &&
in_array($columnDef['type'], ['integer', 'biginteger'])
) {
Expand Down
1 change: 0 additions & 1 deletion tests/TestCase/Database/Schema/PostgresSchemaTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -372,7 +372,6 @@ public function testDescribeTableCompositeKey()
$this->assertTrue($result->column('id')['autoIncrement'], 'id should be autoincrement');
}


/**
* Test describing a table containing defaults with Postgres
*
Expand Down
6 changes: 4 additions & 2 deletions tests/TestCase/ORM/TableTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -4063,7 +4063,8 @@ public function testEntitySource()
*
* @return void
*/
public function skipIfSqlite() {
public function skipIfSqlite()
{
$this->skipIf(
$this->connection->driver() instanceof \Cake\Database\Driver\Sqlite,
'SQLite does not support the requrirements of this test.'
Expand All @@ -4075,7 +4076,8 @@ public function skipIfSqlite() {
*
* @return void
*/
public function skipIfSqlServer() {
public function skipIfSqlServer()
{
$this->skipIf(
$this->connection->driver() instanceof \Cake\Database\Driver\Sqlserver,
'SQLServer does not support the requirements of this test.'
Expand Down

0 comments on commit 8c69ebf

Please sign in to comment.