class CronLoggingUpdateTest

Tests update of system.cron:logging.

@group system @covers \system_post_update_set_cron_logging_setting_to_boolean

Hierarchy

Expanded class hierarchy of CronLoggingUpdateTest

File

core/modules/system/tests/src/Functional/Update/CronLoggingUpdateTest.php, line 16

Namespace

Drupal\Tests\system\Functional\Update
View source
class CronLoggingUpdateTest extends UpdatePathTestBase {
  use UpdatePathTestTrait;
  
  /**
   * {@inheritdoc}
   */
  protected $defaultTheme = 'stark';
  
  /**
   * {@inheritdoc}
   */
  protected function setDatabaseDumpFiles() {
    $this->databaseDumpFiles = [
      DRUPAL_ROOT . '/core/modules/system/tests/fixtures/update/drupal-9.4.0.bare.standard.php.gz',
    ];
  }
  
  /**
   * Tests update of system.cron:logging.
   */
  public function testUpdate() : void {
    $logging_before = $this->config('system.cron')
      ->get('logging');
    $this->assertIsNotBool($logging_before);
    $this->runUpdates();
    $logging_after = $this->config('system.cron')
      ->get('logging');
    $this->assertIsBool($logging_after);
  }

}

Members

Title Sort descending Modifiers Object type Summary
CronLoggingUpdateTest::$defaultTheme protected property The theme to install as the default for testing.
CronLoggingUpdateTest::setDatabaseDumpFiles protected function Set database dump files to be used.
CronLoggingUpdateTest::testUpdate public function Tests update of system.cron:logging.

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