Skip to content

Commit

Permalink
DataAccessTest::testFetchColumnNonExistingIndex() since it covers a b…
Browse files Browse the repository at this point in the history
…ug in PDO
  • Loading branch information
morozov committed Nov 30, 2018
1 parent 9dbec4b commit 4d40426
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 16 deletions.
4 changes: 4 additions & 0 deletions UPGRADE.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Upgrade to 2.9

## Deprecated `Statement::fetchColumn()` with an invalid index

Calls to `Statement::fetchColumn()` with an invalid column index currently return `NULL`. In the future, such calls will result in a exception.

## Deprecated `Configuration::getFilterSchemaAssetsExpression()`, `::setFilterSchemaAssetsExpression()` and `AbstractSchemaManager::getFilterSchemaAssetsExpression()`.

Regular expression-based filters are hard to extend by combining together. Instead, you may use callback-based filers via `::getSchemaAssetsFilter()` and `::getSchemaAssetsFilter()`. Callbacks can use regular expressions internally.
Expand Down
16 changes: 0 additions & 16 deletions tests/Doctrine/Tests/DBAL/Functional/DataAccessTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -891,22 +891,6 @@ public function testFetchColumnNullValue()
);
}

/**
* @group DBAL-1028
*/
public function testFetchColumnNonExistingIndex()
{
if ($this->connection->getDriver()->getName() === 'pdo_sqlsrv') {
$this->markTestSkipped(
'Test does not work for pdo_sqlsrv driver as it throws a fatal error for a non-existing column index.'
);
}

self::assertNull(
$this->connection->fetchColumn('SELECT test_int FROM fetch_table WHERE test_int = ?', [1], 1)
);
}

/**
* @group DBAL-1028
*/
Expand Down

0 comments on commit 4d40426

Please sign in to comment.