class EnsurePHPStanVersionsMatchTest

Same name and namespace in other branches
  1. 11.x core/tests/PHPStan/tests/EnsurePHPStanVersionsMatchTest.php \Drupal\PHPStan\Tests\EnsurePHPStanVersionsMatchTest

Tests that PHPStan version used for rules testing matches core.

Attributes

#[Group('PHPStan')]

Hierarchy

Expanded class hierarchy of EnsurePHPStanVersionsMatchTest

File

core/tests/PHPStan/tests/EnsurePHPStanVersionsMatchTest.php, line 13

Namespace

Drupal\PHPStan\Tests
View source
class EnsurePHPStanVersionsMatchTest extends TestCase {
  public function testVersions() : void {
    $test_composer = json_decode(file_get_contents(__DIR__ . '/../composer.json'), TRUE);
    $drupal_composer = json_decode(file_get_contents(__DIR__ . '/../../../../composer/Metapackage/PinnedDevDependencies/composer.json'), TRUE);
    $this->assertSame($test_composer['require-dev']['phpstan/phpstan'], $drupal_composer['require']['phpstan/phpstan']);
  }

}

Members

Title Sort descending Modifiers Object type Summary
EnsurePHPStanVersionsMatchTest::testVersions public function

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