function PackageManagerKernelTestBase::setUp

Overrides KernelTestBase::setUp

12 calls to PackageManagerKernelTestBase::setUp()
BaseRequirementsFulfilledValidatorTest::setUp in core/modules/package_manager/tests/src/Kernel/BaseRequirementsFulfilledValidatorTest.php
ChangeLoggerTest::setUp in core/modules/package_manager/tests/src/Kernel/ChangeLoggerTest.php
FixtureManipulatorTest::setUp in core/modules/package_manager/tests/src/Kernel/FixtureManipulatorTest.php
GitExcluderTest::setUp in core/modules/package_manager/tests/src/Kernel/PathExcluder/GitExcluderTest.php
LockFileValidatorTest::setUp in core/modules/package_manager/tests/src/Kernel/LockFileValidatorTest.php

... See full list

12 methods override PackageManagerKernelTestBase::setUp()
BaseRequirementsFulfilledValidatorTest::setUp in core/modules/package_manager/tests/src/Kernel/BaseRequirementsFulfilledValidatorTest.php
ChangeLoggerTest::setUp in core/modules/package_manager/tests/src/Kernel/ChangeLoggerTest.php
FixtureManipulatorTest::setUp in core/modules/package_manager/tests/src/Kernel/FixtureManipulatorTest.php
GitExcluderTest::setUp in core/modules/package_manager/tests/src/Kernel/PathExcluder/GitExcluderTest.php
LockFileValidatorTest::setUp in core/modules/package_manager/tests/src/Kernel/LockFileValidatorTest.php

... See full list

File

core/modules/package_manager/tests/src/Kernel/PackageManagerKernelTestBase.php, line 114

Class

PackageManagerKernelTestBase
Base class for kernel tests of Package Manager's functionality.

Namespace

Drupal\Tests\package_manager\Kernel

Code

protected function setUp() : void {
    parent::setUp();
    $this->installConfig('package_manager');
    $this->fileSystem = new Filesystem();
    $this->createTestProject();
    // The Update module's default configuration must be installed for our
    // fake release metadata to be fetched, and the System module's to ensure
    // the site has a name.
    $this->installConfig([
        'system',
        'update',
    ]);
    // Make the update system think that all of System's post-update functions
    // have run.
    $this->registerPostUpdateFunctions();
    // Ensure we can fail the test if any warnings, or worse, are logged by
    // Package Manager.
    // @see ::tearDown()
    $this->failureLogger = new TestLogger();
    $this->container
        ->get('logger.channel.package_manager')
        ->addLogger($this->failureLogger);
}

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