function FeedAdminDisplayTest::randomMachineName
Generates a unique random string containing letters and numbers.
Do not use this method when testing unvalidated user input. Instead, use \Drupal\simpletest\TestBase::randomString().
Parameters
int $length: Length of random string to generate.
Return value
string Randomly generated unique string.
Overrides RandomGeneratorTrait::randomMachineName
File
- 
              core/modules/ aggregator/ tests/ src/ Functional/ FeedAdminDisplayTest.php, line 72 
Class
- FeedAdminDisplayTest
- Tests the display of a feed on the Aggregator list page.
Namespace
Drupal\Tests\aggregator\FunctionalCode
public function randomMachineName($length = 8) {
  $value = parent::randomMachineName($length);
  // See expected values in testFeedUpdateFields().
  $value = str_replace([
    'never',
    'imminently',
    'ago',
    'left',
  ], 'x', $value);
  return $value;
}Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.
