function UrlHelperTest::providerTestValidAbsoluteData

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

Data provider for testValidAbsolute().

Return value

array

File

core/tests/Drupal/Tests/Component/Utility/UrlHelperTest.php, line 52

Class

UrlHelperTest
@group Utility

Namespace

Drupal\Tests\Component\Utility

Code

public function providerTestValidAbsoluteData() {
    $urls = [
        'example.com',
        'www.example.com',
        'ex-ample.com',
        '3xampl3.com',
        'example.com/parenthesis',
        'example.com/index.html#pagetop',
        'example.com:8080',
        'subdomain.example.com',
        'example.com/index.php/node',
        'example.com/index.php/node?param=false',
        'user@www.example.com',
        'user:pass@www.example.com:8080/login.php?do=login&style=%23#pagetop',
        '127.0.0.1',
        'example.org?',
        'john%20doe:secret:foo@example.org/',
        'example.org/~,$\'*;',
        'caf%C3%A9.example.org',
        // cspell:ignore FEDC
'[FEDC:BA98:7654:3210:FEDC:BA98:7654:3210]:80/index.html',
    ];
    return $this->dataEnhanceWithScheme($urls);
}

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