Verified Commit 4ef3e3b7 authored by Dave Long's avatar Dave Long
Browse files

test: #3585455 Fix return types and baselined errors of core/tests/ Unit code - round 6

By: mondrake
By: smustgrave
By: longwave
parent 2aa5aede
Loading
Loading
Loading
Loading
+66 −1116

File changed.

Preview size limit exceeded, changes collapsed.

+2 −2
Original line number Diff line number Diff line
@@ -17,7 +17,7 @@ class ArgumentsResolver implements ArgumentsResolverInterface {
  /**
   * An associative array of parameter names to object candidate values.
   *
   * @var array
   * @var array<string,object>
   */
  protected $objects;

@@ -33,7 +33,7 @@ class ArgumentsResolver implements ArgumentsResolverInterface {
   *
   * @param array $scalars
   *   An associative array of parameter names to scalar candidate values.
   * @param object[] $objects
   * @param array<string,object> $objects
   *   An associative array of parameter names to object candidate values.
   * @param object[] $wildcards
   *   An array object candidates tried on every parameter regardless of its
+2 −2
Original line number Diff line number Diff line
@@ -26,7 +26,7 @@ trait SynchronizeCsrfTokenSeedTrait {
  /**
   * {@inheritdoc}
   */
  protected function drupalLogin(AccountInterface $account) {
  protected function drupalLogin(AccountInterface $account): void {
    parent::drupalLogin($account);
    $session_data = $this->container->get('session_handler.write_safe')->read($this->getSession()->getCookie($this->getSessionName()));
    $csrf_token_seed = unserialize(explode('_sf2_meta|', $session_data)[1])['s'];
@@ -50,7 +50,7 @@ protected function rebuildContainer() {
  /**
   * {@inheritdoc}
   */
  protected function drupalLogout() {
  protected function drupalLogout(): void {
    parent::drupalLogout();
    $this->container->get('session_manager.metadata_bag')->stampNew();
  }
+1 −0
Original line number Diff line number Diff line
@@ -37,6 +37,7 @@ parameters:
    - ../*/node_modules/*
    - */fixtures/*.php
    - */fixtures/*.php.gz
    - tests/Drupal/Tests/Component/Annotation/Doctrine/Fixtures
    # Skip the phpstan tmpDir
    - phpstan-tmp/*
    # Skip Drupal's own PHPStan rules test fixtures.
+2 −2
Original line number Diff line number Diff line
@@ -47,7 +47,7 @@ abstract class WebDriverTestBase extends BrowserTestBase {
  /**
   * {@inheritdoc}
   */
  protected $minkDefaultDriverClass = DrupalSelenium2Driver::class;
  protected string $minkDefaultDriverClass = DrupalSelenium2Driver::class;

  /**
   * {@inheritdoc}
@@ -99,7 +99,7 @@ protected function initFrontPage(): void {
   * {@inheritdoc}
   */
  protected function tearDown(): void {
    if ($this->mink) {
    if (isset($this->mink)) {
      // Wait for all requests to finish. It is possible that an AJAX request is
      // still on-going.
      $result = $this->getSession()->wait(5000, 'window.drupalActiveXhrCount === 0 || typeof window.drupalActiveXhrCount === "undefined"');
Loading