function AssertHelperTraitTest::providerCastSafeStrings

Same name and namespace in other branches
  1. 8.9.x core/tests/Drupal/Tests/AssertHelperTraitTest.php \Drupal\Tests\AssertHelperTraitTest::providerCastSafeStrings()

File

core/tests/Drupal/Tests/AssertHelperTraitTest.php, line 31

Class

AssertHelperTraitTest
@coversDefaultClass <a href="/api/drupal/core%21tests%21Drupal%21Tests%21AssertHelperTrait.php/trait/AssertHelperTrait/9" title="Provides helper methods for assertions." class="local">\Drupal\Tests\AssertHelperTrait</a> @group simpletest @group Tests @group legacy

Namespace

Drupal\Tests

Code

public function providerCastSafeStrings() {
    $safe_string = Markup::create('test safe string');
    return [
        [
            'test simple string',
            'test simple string',
        ],
        [
            [
                'test simple array',
                'test simple array',
            ],
            [
                'test simple array',
                'test simple array',
            ],
        ],
        [
            'test safe string',
            $safe_string,
        ],
        [
            [
                'test safe string',
                'test safe string',
            ],
            [
                $safe_string,
                $safe_string,
            ],
        ],
        [
            [
                'test safe string',
                'mixed array',
                'test safe string',
            ],
            [
                $safe_string,
                'mixed array',
                $safe_string,
            ],
        ],
    ];
}

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