function ContainerTest::getIterator

Same name in other branches
  1. 10 core/tests/Drupal/Tests/Component/DependencyInjection/ContainerTest.php \Drupal\Tests\Component\DependencyInjection\ContainerTest::getIterator()

Helper function to return a service iterator.

1 call to ContainerTest::getIterator()
ContainerTest::getMockContainerDefinition in core/tests/Drupal/Tests/Component/DependencyInjection/ContainerTest.php
Gets a mock container definition.

File

core/tests/Drupal/Tests/Component/DependencyInjection/ContainerTest.php, line 1039

Class

ContainerTest
@coversDefaultClass \Drupal\Component\DependencyInjection\Container @group DependencyInjection

Namespace

Drupal\Tests\Component\DependencyInjection

Code

protected function getIterator($iterator) {
    return (object) [
        'type' => 'iterator',
        'value' => $iterator,
    ];
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.