function UpdateReportTest::providerTemplatePreprocessUpdateReport

Same name and namespace in other branches
  1. 9 core/modules/update/tests/src/Kernel/UpdateReportTest.php \Drupal\Tests\update\Kernel\UpdateReportTest::providerTemplatePreprocessUpdateReport()
  2. 10 core/modules/update/tests/src/Kernel/UpdateReportTest.php \Drupal\Tests\update\Kernel\UpdateReportTest::providerTemplatePreprocessUpdateReport()
  3. 11.x core/modules/update/tests/src/Kernel/UpdateReportTest.php \Drupal\Tests\update\Kernel\UpdateReportTest::providerTemplatePreprocessUpdateReport()

Provides data for testTemplatePreprocessUpdateReport().

Return value

array Array of $variables for template_preprocess_update_report().

File

core/modules/update/tests/src/Kernel/UpdateReportTest.php, line 43

Class

UpdateReportTest
Tests update report functionality.

Namespace

Drupal\Tests\update\Kernel

Code

public function providerTemplatePreprocessUpdateReport() {
    return [
        '$variables with data not set' => [
            [],
        ],
        '$variables with data as an interger' => [
            [
                'data' => 4,
            ],
        ],
        '$variables with data as a string' => [
            [
                'data' => 'I am a string',
            ],
        ],
    ];
}

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