function PoStreamWriterTest::providerWriteData

Same name in other branches
  1. 8.9.x core/tests/Drupal/Tests/Component/Gettext/PoStreamWriterTest.php \Drupal\Tests\Component\Gettext\PoStreamWriterTest::providerWriteData()
  2. 10 core/tests/Drupal/Tests/Component/Gettext/PoStreamWriterTest.php \Drupal\Tests\Component\Gettext\PoStreamWriterTest::providerWriteData()
  3. 11.x core/tests/Drupal/Tests/Component/Gettext/PoStreamWriterTest.php \Drupal\Tests\Component\Gettext\PoStreamWriterTest::providerWriteData()

Return value

array

  • Content to write.
  • Written content.
  • Content longer than 10 bytes.

File

core/tests/Drupal/Tests/Component/Gettext/PoStreamWriterTest.php, line 89

Class

PoStreamWriterTest
@coversDefaultClass \Drupal\Component\Gettext\PoStreamWriter @group Gettext

Namespace

Drupal\Tests\Component\Gettext

Code

public function providerWriteData() {
    // cSpell:disable
    return [
        [
            '',
            '',
            FALSE,
        ],
        [
            "\r\n",
            "\r\n",
            FALSE,
        ],
        [
            'write this if you can',
            'write this',
            TRUE,
        ],
        [
            'éáíó>&',
            'éáíó>&',
            FALSE,
        ],
        [
            'éáíó>&<',
            'éáíó>&',
            TRUE,
        ],
        [
            '中文 890',
            '中文 890',
            FALSE,
        ],
        [
            '中文 89012',
            '中文 890',
            TRUE,
        ],
    ];
    // cSpell:enable
}

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