$this->
setMockContainerService('path.validator'
);
$this->
assertNotNull(\Drupal::
pathValidator());
} /**
* Tests the accessManager() method.
*
* @covers ::accessManager
*/
public function testAccessManager() { $this->
setMockContainerService('access_manager'
);
$this->
assertNotNull(\Drupal::
accessManager());
} /**
* Tests the PHP constants have consistent values.
*/
public function testPhpConstants() { // RECOMMENDED_PHP can be just MAJOR.MINOR so normalize it to allow using
// version_compare().
$normalizer =
function Dstring
$version): string
{ // The regex below is from \Composer\Semver\VersionParser::normalize().
preg_match('{^(\d{1,5})(\.\d++)?(\.\d++)?$}i',
$version,
$matches);