Behat/Behat — pull request #430 by stof (2014-01-11 01:06:20+00:00)
Title: Fixed the GroupedSubjectIterator when dealing with an empty iterator

If one of the subject iterators is empty, the GroupedSubjectIterator needs to move to the next iterator, otherwise the iteration will be incomplete.

I detected this by running the Symfony2Extension suites: https://travis-ci.org/Behat/Symfony2Extension/jobs/16745992
When the locator is not used, the BundleFeatureLocator returns an empty iterator, and it has an higher priority than the core locator so the empty iterator comes first when grouping. Because of the previous logic, rewinding the grouped iterator would set it on the first iterator so ``->valid()`` would return ``false`` and the iteration would stop without ever reaching the next iterator. The same change was required in ``next`` for empty iterators later in the group.