Google\Cloud\Tests\BigQuery\TableTest::testGetsRowsWithToken PHP Method

testGetsRowsWithToken() public method

    public function testGetsRowsWithToken()
    {
        $name = 'Mike';
        $secondRowData = $this->rowData;
        $secondRowData['rows'][0]['f'][0]['v'] = $name;
        $this->connection->getTable(Argument::any())->willReturn($this->schemaData)->shouldBeCalledTimes(1);
        $this->connection->listTableData(Argument::any())->willReturn($this->rowData + ['nextPageToken' => 'abc'], $secondRowData)->shouldBeCalledTimes(2);
        $table = $this->getTable($this->connection);
        $rows = iterator_to_array($table->rows());
        $this->assertEquals($name, $rows[1]['first_name']);
    }