Fix + tests for #5969

Added test for issue #5969 per request of @weierophinney and @feliperamaral

Might need to be cleaned up and moved, but it does demonstrate the problem. Running the test without the fix shows the error:

```
thorie@tim-mbp:~/work/zf2/tests$ phpunit --filter testSelectWithArrayTable ZendTest/Db/TableGateway/AbstractTableGatewayTest.php 
PHPUnit 3.7.19 by Sebastian Bergmann.

Configuration read from /Users/thorie/work/zf2/tests/phpunit.xml

E

Time: 32 ms, Memory: 10.50Mb

There was 1 error:

1) ZendTest\Db\TableGateway\AbstractTableGatewayTest::testSelectWithArrayTable
Zend\Db\TableGateway\Exception\RuntimeException: The table name of the provided select object must match that of the table

/Users/thorie/work/zf2/library/Zend/Db/TableGateway/AbstractTableGateway.php:220
/Users/thorie/work/zf2/library/Zend/Db/TableGateway/AbstractTableGateway.php:208
/Users/thorie/work/zf2/tests/ZendTest/Db/TableGateway/AbstractTableGatewayTest.php:206
/usr/lib/php/pear/PHPUnit/TextUI/Command.php:176
/usr/lib/php/pear/PHPUnit/TextUI/Command.php:129

FAILURES!
Tests: 1, Assertions: 1, Errors: 1.
```