Skip to content

Loading…

DDC-2257: [GH-555] Failing test case for iterable ObjectHydrator #2957

Closed
doctrinebot opened this Issue · 4 comments

2 participants

@doctrinebot

Jira issue originally created by user @beberlei:

This issue is created automatically through a Github pull request on behalf of everzet:

Url: #555

Message:

Here's the deal, whether you're using ObjectHydrator::iterate() on query with scalars, on each consequent iteration scalars go into advanced subarray. In terms of failing test case, we're getting:

- iteration #1
  array(1) {
    [0]=> array(2) {
      ["id"]=> string(1) "1"
      ["name"]=> string(6) "romanb"
    }
  }
- iteration #2
  array(1) {
    [1]=> array(2) {
      ["id"]=> string(1) "2"
      ["name"]=> string(5) "jwage"
    }
  }
- iteration #3
  array(1) {
    [2]=> array(2) {
      ["id"]=> string(1) "3"
      ["name"]=> string(7) "everzet"
    }
  }

Where in reality we expect:

- iteration #1
  array(1) {
    [0]=> array(2) {
      ["id"]=> string(1) "1"
      ["name"]=> string(6) "romanb"
    }
  }
- iteration #2
  array(1) {
    [0]=> array(2) {
      ["id"]=> string(1) "2"
      ["name"]=> string(5) "jwage"
    }
  }
- iteration #3
  array(1) {
    [0]=> array(2) {
      ["id"]=> string(1) "3"
      ["name"]=> string(7) "everzet"
    }
  }
@doctrinebot

Comment created by @beberlei:

Documented behavior

@doctrinebot

Issue was closed with resolution "Invalid"

@doctrinebot

Comment created by @doctrinebot:

A related Github Pull-Request [GH-555] was closed:
#555

@doctrinebot

Comment created by @doctrinebot:

A related Github Pull-Request [GH-555] was closed:
doctrine/dbal#555

@beberlei beberlei was assigned by doctrinebot
@doctrinebot doctrinebot closed this
@doctrinebot doctrinebot added the Bug label
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.