Commit 512f0018 authored by Benjamin Eberlei's avatar Benjamin Eberlei

[DBAL-435] Add functional test to verify empty parameters behavior.

parent c5b4c9e6
...@@ -548,6 +548,18 @@ class DataAccessTest extends \Doctrine\Tests\DbalFunctionalTestCase ...@@ -548,6 +548,18 @@ class DataAccessTest extends \Doctrine\Tests\DbalFunctionalTestCase
} }
} }
/**
* @group DBAL-435
*/
public function testEmptyParameters()
{
$sql = "SELECT * FROM fetch_table WHERE test_int IN (?)";
$stmt = $this->_conn->executeQuery($sql, array(array()), array(\Doctrine\DBAL\Connection::PARAM_INT_ARRAY));
$rows = $stmt->fetchAll();
$this->assertEquals(array(), $rows);
}
private function setupFixture() private function setupFixture()
{ {
$this->_conn->executeQuery('DELETE FROM fetch_table')->execute(); $this->_conn->executeQuery('DELETE FROM fetch_table')->execute();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment