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
Currently the protected method FeaturesManager::getConfigDependency()
tests for InstallStorage::CONFIG_INSTALL_DIRECTORY
, but not when adding a dependency on the module providing a config type. The test should be applied in either case, since no dependencies should be added for optional config.
Proposed resolution
Remaining tasks
User interface changes
API changes
Data model changes
Comment | File | Size | Author |
---|---|---|---|
#20 | features-optional-dependency-2845779-20.patch | 4.1 KB | nedjo |
| |||
#18 | features-optional-dependency-2845779-18.patch | 4.03 KB | nedjo |
#17 | features-optional-dependency-2845779-17.patch | 3.73 KB | nedjo |
| |||
#15 | features-optional-dependency-2845779-15-test-only.patch | 1.92 KB | nedjo |
Comments
Comment #2
nedjoComment #4
JeffM2001 CreditAttribution: JeffM2001 commentedUpdated the patch so that it also skips inter-package dependencies for optional config.
Comment #5
JeffM2001 CreditAttribution: JeffM2001 commentedSorry, missed a line in that last patch.
Comment #6
JeffM2001 CreditAttribution: JeffM2001 commentedUgh. I tested it and it was working, but then I did some formatting to make the code more readable and messed things up. Sorry about that. This time, I retested before uploading the patch.
Comment #10
mpotter CreditAttribution: mpotter at Phase2 commentedTriggered a new test now that the Features branch is working again.
Comment #12
mpotter CreditAttribution: mpotter at Phase2 commentedNot sure why the testbot doesn't give useful results, but here is the test result when I run it locally:
So some work on this is still needed.
Comment #13
smustgrave CreditAttribution: smustgrave commentedRerolled this against the latest version of dev.
Removed the last part because it was already added it appears.
Also had to change
$provider = $this->entityManager->getDefinition($type)->getProvider();
To
$provider = $this->entityTypeManager->getDefinition($type)->getProvider();
Very small tweak but appears to be working after initial testing.
Comment #14
smustgrave CreditAttribution: smustgrave commentedI don't understand Drupal 8 unit testing well enough to know why it's failing.
Comment #15
nedjoTest-only patch. This should fail.
Comment #17
nedjoAnd with the fix.
Comment #18
nedjoAddressing merge conflicts.
Comment #20
nedjoFixing up test.
Comment #22
nedjo