Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Problem/Motivation
As mentioned in #8 on #3161582-8: EntityContextDefinition breaks the context system testing at D9 fails for rules/tests/src/Unit/Integration/RulesEntityIntegrationTestBase.php on line 52
Uncaught require_once( .... /drupal/core/includes/entity.inc): failed to open stream: No such file or directory
This file no longer exists at core 9.0.
Steps to reproduce
Run tests at Core 9.0
Proposed resolution
Remove this line. Tests run OK at 8.8, 8.9 and 9.0 without it. It must have been required for some previous version of the unit test, but is no longer needed now.
Comment | File | Size | Author |
---|---|---|---|
#4 | 3162246-4.remove-require-once-includes-entity-inc.patch | 9.59 KB | jonathan1055 |
| |||
#2 | 3162246-2.remove-require-once-includes-entity-inc.patch | 684 bytes | jonathan1055 |
Comments
Comment #2
jonathan1055 CreditAttribution: jonathan1055 as a volunteer commentedPatch.
Comment #3
jonathan1055 CreditAttribution: jonathan1055 as a volunteer commentedI know this won't work, but just trying it at D9 to see how it fails.
Comment #4
jonathan1055 CreditAttribution: jonathan1055 as a volunteer commentedWith the changes from #3161582: EntityContextDefinition breaks the context system
Comment #5
jonathan1055 CreditAttribution: jonathan1055 as a volunteer commentedSo, that worked nicely. Might be the first green fully passing Rules test suite at D9 on drupal.org. [but TR has done the real work here]
Obviously, patch #2 is the one to commit, patch #4 was just a try-out, and those fixes are done elsewhere. But good to know we can run at D9 now :-)
Comment #6
jonathan1055 CreditAttribution: jonathan1055 as a volunteer commentedNeeds Review, but I'd say this could be RTBC
Comment #8
TR CreditAttribution: TR commentedAll of the functions in
entity.inc
(entity_load()
,entity_create()
, etc.) had been deprecated as of Drupal 8.8.0 (or earlier). So we actually needed to includeentity.inc
while core Drupal 8.7 was still supported. Now that D8.7 is done with it is safe to remove this.Committed #2.