function RunnerVersion::getMajor
Same name in other branches
- 9 core/tests/Drupal/TestTools/PhpUnitCompatibility/RunnerVersion.php \Drupal\TestTools\PhpUnitCompatibility\RunnerVersion::getMajor()
- 8.9.x core/tests/Drupal/TestTools/PhpUnitCompatibility/RunnerVersion.php \Drupal\TestTools\PhpUnitCompatibility\RunnerVersion::getMajor()
- 11.x core/tests/Drupal/TestTools/PhpUnitCompatibility/RunnerVersion.php \Drupal\TestTools\PhpUnitCompatibility\RunnerVersion::getMajor()
Returns the major version of the PHPUnit runner being used.
Return value
int The major version of the PHPUnit runner being used.
2 calls to RunnerVersion::getMajor()
- PhpUnitCliTest::testPhpUnitListTests in core/
tests/ Drupal/ Tests/ Core/ Test/ PhpUnitCliTest.php - Ensure that the test suites are able to discover tests without incident.
- PhpUnitCompatibilityTrait.php in core/
tests/ Drupal/ Tests/ PhpUnitCompatibilityTrait.php
File
-
core/
tests/ Drupal/ TestTools/ PhpUnitCompatibility/ RunnerVersion.php, line 28
Class
- RunnerVersion
- Helper class to determine information about running PHPUnit version.
Namespace
Drupal\TestTools\PhpUnitCompatibilityCode
public static function getMajor() {
return (int) explode('.', Version::id())[0];
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.