3.1.x-dev Branch Tests Broken

Created on 4 June 2021, over 3 years ago
Updated 15 August 2023, about 1 year ago

Problem/Motivation

Branch tests for 3.1.x-dev are broken at HEAD:

$ ../vendor/phpunit/phpunit/phpunit -c core/ modules/contrib/permissions_by_term/ --verbose
PHPUnit 8.5.15 by Sebastian Bergmann and contributors.

Runtime:       PHP 7.3.25-1+0~20201130.73+debian10~1.gbp042074
Configuration: /var/www/html/web/core/phpunit.xml.dist

Testing modules/contrib/permissions_by_term/
......................F......                                     29 / 29 (100%)

Time: 4.06 minutes, Memory: 6.00 MB

There was 1 failure:

1) Drupal\Tests\permissions_by_term\Kernel\NodeEntityBundleInfoTest::testGetPermissionsByTids
Failed asserting that two arrays are equal.
--- Expected
+++ Actual
@@ @@
 Array (
     'roleLabels' => Array (
         1 => Array (
-            0 => 'First Role'
+            0 => 'administrator'
+            1 => 'First Role'
+            2 => 'Second Role'
+            3 => 'Third Role'
+        )
+        2 => Array (
+            0 => 'administrator'
             1 => 'Second Role'
             2 => 'Third Role'
-            3 => 'administrator'
-        )
-        2 => Array (
-            0 => 'Second Role'
-            1 => 'Third Role'
-            2 => 'administrator'
         )
     )
     'userDisplayNames' => Array (...)
 )

/var/www/html/vendor/phpunit/phpunit/src/Framework/Constraint/IsEqual.php:100
/var/www/html/vendor/phpunit/phpunit/src/Framework/Assert.php:2924
/var/www/html/vendor/phpunit/phpunit/src/Framework/Assert.php:629
/var/www/html/web/modules/contrib/permissions_by_term/tests/src/Kernel/NodeEntityBundleInfoTest.php:102
/var/www/html/vendor/phpunit/phpunit/src/Framework/TestResult.php:703

FAILURES!
Tests: 29, Assertions: 404, Failures: 1.

Remaining self deprecation notices (72)

  29x: Installing the tables key_value and key_value_expire with the method KernelTestBase::installSchema() is deprecated in drupal:9.1.0 and is removed from drupal:10.0.0. The tables are now lazy loaded and therefore will be installed automatically when used. See https://www.drupal.org/node/3143286
    1x in EntityAccessCheckTest::testBaseAccessControl from Drupal\Tests\permissions_by_entity\Kernel
    1x in AccessStorageTest::testSaveMultipleLanguageCodes from Drupal\Tests\permissions_by_term\Kernel
    1x in PermissionModeTest::testNodeAccessRecordCreation from Drupal\Tests\permissions_by_term\Kernel
    1x in PermissionModeTest::testHandleNodeAsAdmin from Drupal\Tests\permissions_by_term\Kernel
    1x in PermissionModeTest::testHandleNode from Drupal\Tests\permissions_by_term\Kernel
    1x in PermissionModeTest::testCanAdminUserAccessByNodeId from Drupal\Tests\permissions_by_term\Kernel
    1x in PermissionModeTest::testCanUserAccessByNodeId from Drupal\Tests\permissions_by_term\Kernel
    1x in NodeEntityBundleInfoTest::testGetPermissionsByTids from Drupal\Tests\permissions_by_term\Kernel
    1x in NodeAccessRecordsTest::testCreateIfTermHasNoPermissionButPermissionModeIsOn from Drupal\Tests\permissions_by_term\Kernel
    1x in NodeAccessRecordsTest::testCreateIfTermHasPermission from Drupal\Tests\permissions_by_term\Kernel
    1x in NodeAccessRecordsTest::testCreateNone from Drupal\Tests\permissions_by_term\Kernel
    1x in MultilingualTest::testCanNotAccess from Drupal\Tests\permissions_by_term\Kernel
    1x in MultilingualTest::testCanAccess from Drupal\Tests\permissions_by_term\Kernel
    1x in AccessStorageTest::testTidsByNidRetrieval from Drupal\Tests\permissions_by_term\Kernel
    1x in AccessCheckTest::testIsAnyTaxonomyTermFieldDefinedInNodeType from Drupal\Tests\permissions_by_term\Kernel
    1x in EntityAccessCheckTest::testAnonymousAccessDeniedUsingKernel from Drupal\Tests\permissions_by_entity\Kernel
    1x in AccessCheckTest::testBypassNodeAccess from Drupal\Tests\permissions_by_term\Kernel
    1x in AccessCheckTest::testCheckAccessAsGuestWithTermRestriction from Drupal\Tests\permissions_by_term\Kernel
    1x in AccessCheckTest::testCheckAccessAsGuestWithNoTermRestriction from Drupal\Tests\permissions_by_term\Kernel
    1x in AccessCheckTest::testRequireAllTermsGrantedWithNoRestrictedTerms from Drupal\Tests\permissions_by_term\Kernel
    1x in AccessCheckTest::testRequireAllTermsGrantedWithRestrictedTerms from Drupal\Tests\permissions_by_term\Kernel
    1x in AccessCheckTest::testNoTermRestriction from Drupal\Tests\permissions_by_term\Kernel
    1x in AccessCheckTest::testNoGrantedTermRestriction from Drupal\Tests\permissions_by_term\Kernel
    1x in AccessCheckTest::testDisabledRequireAllTermsGranted from Drupal\Tests\permissions_by_term\Kernel
    1x in EntityPublicationTest::testAnonymousCannotViewUnpublishedNodesWithoutTermPermissions from Drupal\Tests\permissions_by_entity\Kernel
    1x in EntityPublicationTest::testAnonymousCanViewPublishedNodesWithoutTermPermissions from Drupal\Tests\permissions_by_entity\Kernel
    1x in EntityAccessCheckTest::testAuthenticatedDeniedOnCachedAccessUsingKernel from Drupal\Tests\permissions_by_entity\Kernel
    1x in EntityAccessCheckTest::testAuthenticatedAccessUsingKernel from Drupal\Tests\permissions_by_entity\Kernel
    1x in TermHandlerTest::testGetTidsBoundForAllNids from Drupal\Tests\permissions_by_term\Kernel

  9x: The Drupal\Tests\permissions_by_term\Kernel\AccessCheckTest::$modules property must be declared protected. See https://www.drupal.org/node/2909426
    9x in DrupalListener::startTest from Drupal\Tests\Listeners

  5x: The Drupal\Tests\permissions_by_term\Kernel\PermissionModeTest::$modules property must be declared protected. See https://www.drupal.org/node/2909426
    5x in DrupalListener::startTest from Drupal\Tests\Listeners

  4x: Declaring ::setUp without a void return typehint in Drupal\Tests\permissions_by_entity\Kernel\EntityAccessCheckTest is deprecated in drupal:9.0.0. Typehinting will be required before drupal:10.0.0. See https://www.drupal.org/node/3114724
    4x in DrupalListener::startTest from Drupal\Tests\Listeners

  4x: The Drupal\Tests\permissions_by_entity\Kernel\EntityAccessCheckTest::$modules property must be declared protected. See https://www.drupal.org/node/2909426
    4x in DrupalListener::startTest from Drupal\Tests\Listeners

  3x: The Drupal\Tests\permissions_by_term\Kernel\NodeAccessRecordsTest::$modules property must be declared protected. See https://www.drupal.org/node/2909426
    3x in DrupalListener::startTest from Drupal\Tests\Listeners

  2x: The Drupal\Tests\permissions_by_term\Kernel\MultilingualTest::$modules property must be declared protected. See https://www.drupal.org/node/2909426
    2x in DrupalListener::startTest from Drupal\Tests\Listeners

  2x: Declaring ::setUp without a void return typehint in Drupal\Tests\permissions_by_term\Kernel\MultilingualTest is deprecated in drupal:9.0.0. Typehinting will be required before drupal:10.0.0. See https://www.drupal.org/node/3114724
    2x in DrupalListener::startTest from Drupal\Tests\Listeners

  2x: The Drupal\Tests\permissions_by_term\Kernel\AccessStorageTest::$modules property must be declared protected. See https://www.drupal.org/node/2909426
    2x in DrupalListener::startTest from Drupal\Tests\Listeners

  2x: Declaring ::setUp without a void return typehint in Drupal\Tests\permissions_by_term\Kernel\AccessStorageTest is deprecated in drupal:9.0.0. Typehinting will be required before drupal:10.0.0. See https://www.drupal.org/node/3114724
    2x in DrupalListener::startTest from Drupal\Tests\Listeners

  2x: The Drupal\Tests\permissions_by_entity\Kernel\EntityPublicationTest::$modules property must be declared protected. See https://www.drupal.org/node/2909426
    2x in DrupalListener::startTest from Drupal\Tests\Listeners

  2x: Declaring ::setUp without a void return typehint in Drupal\Tests\permissions_by_entity\Kernel\EntityPublicationTest is deprecated in drupal:9.0.0. Typehinting will be required before drupal:10.0.0. See https://www.drupal.org/node/3114724
    2x in DrupalListener::startTest from Drupal\Tests\Listeners

  1x: AssertLegacyTrait::assertNotEqual() is deprecated in drupal:8.0.0 and is removed from drupal:10.0.0. Use $this->assertNotEquals() instead. See https://www.drupal.org/node/3129738
    1x in EntityPublicationTest::testAnonymousCanViewPublishedNodesWithoutTermPermissions from Drupal\Tests\permissions_by_entity\Kernel

  1x: Declaring ::setUp without a void return typehint in Drupal\Tests\permissions_by_term\Kernel\NodeEntityBundleInfoTest is deprecated in drupal:9.0.0. Typehinting will be required before drupal:10.0.0. See https://www.drupal.org/node/3114724
    1x in DrupalListener::startTest from Drupal\Tests\Listeners

  1x: The Drupal\Tests\permissions_by_term\Kernel\NodeEntityBundleInfoTest::$modules property must be declared protected. See https://www.drupal.org/node/2909426
    1x in DrupalListener::startTest from Drupal\Tests\Listeners

  1x: Calling the Symfony\Component\EventDispatcher\EventDispatcherInterface::dispatch() method with a string event name as the first argument is deprecated in drupal:9.1.0, an Event object will be required instead in drupal:10.0.0. See https://www.drupal.org/node/3154407
    1x in PermissionModeTest::testHandleNode from Drupal\Tests\permissions_by_term\Kernel

  1x: Declaring ::setUp without a void return typehint in Drupal\Tests\permissions_by_term\Kernel\TermHandlerTest is deprecated in drupal:9.0.0. Typehinting will be required before drupal:10.0.0. See https://www.drupal.org/node/3114724
    1x in DrupalListener::startTest from Drupal\Tests\Listeners

  1x: The Drupal\Tests\permissions_by_term\Kernel\TermHandlerTest::$modules property must be declared protected. See https://www.drupal.org/node/2909426
    1x in DrupalListener::startTest from Drupal\Tests\Listeners

Remaining direct deprecation notices (5)

  5x: Calling the "Symfony\Component\EventDispatcher\EventDispatcherInterface::dispatch()" method with the event name as the first argument is deprecated since Symfony 4.3, pass it as the second argument and provide the event object as the first argument instead.
    3x in EntityAccessCheckTest::testAuthenticatedDeniedOnCachedAccessUsingKernel from Drupal\Tests\permissions_by_entity\Kernel
    1x in EntityAccessCheckTest::testAnonymousAccessDeniedUsingKernel from Drupal\Tests\permissions_by_entity\Kernel
    1x in EntityAccessCheckTest::testAuthenticatedAccessUsingKernel from Drupal\Tests\permissions_by_entity\Kernel

Setting to urgent per Issue Priority field β†’

Cause tests to fail in HEAD on the automated testing platform for any supported environment (including random failures), since this blocks all other work.

There are also 70+ deprecation notices, but those can be handled in a follow-up issue once this development blocker has been removed.

Steps to reproduce

Run tests locally

Proposed resolution

Fix failing test

Remaining tasks

Debug and submit patch

User interface changes

None.

API changes

None.

Data model changes

None.

πŸ› Bug report
Status

Fixed

Version

3.1

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States Chris Burge

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024