Problem/Motivation
follow-up #3296261: Add the ability to map package names to project names and vice-versa
Instead of doing #3304142: Do not assume that Composer package names will exactly match Drupal projects names which is to do just conversion everywhere lets first try only taking on the change in ExtensionUpdater. This is will probably mean we need to also fix a bunch of other tests and/or the test fixtures but lets not try to fix all the validators themeselves in 1 issue if we don't have to .
Proposed resolution
Update ExtensionUpdater to use the new methods added in #3296261: Add the ability to map package names to project names and vice-versa. basically don't assume that for project_a the package name will be drupal/project_a but use \Drupal\package_manager\ComposerUtility::getProjectForPackage and \Drupal\package_manager\ComposerUtility::getPackageForProject as needed
This will make many tests fail. update the test and/or fixtures to make them pass.
Remaining tasks
User interface changes
API changes
Data model changes
Issue fork automatic_updates-3305773
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
tedbowComment #4
tedbowComment #5
omkar.podey commentedComment #6
omkar.podey commentedComment #7
omkar.podey commentedComment #8
omkar.podey commentedComment #9
tedbowComment #10
tedbowcreated follow-ups
#3308372: Determine if renaming info.yml.hide files can be done in 1 method for kernel, build, and functional tests
#3308365: Don't allow Drupal profiles to be sent to ExtensionUpdater
I think this is good. Great work @omkar.podey
Will merge when green
Comment #11
tedbowfound some unneeded fixture files
for example automatic_updates_extensions/tests/fixtures/packages_installed_with_composer_validator/theme_not_installed.staged.installed.json
was copied to automatic_updates_extensions/tests/fixtures/packages_installed_with_composer_validator/theme_not_installed_stage/staged.installed.json but the original was not removed
I fixed this
Comment #13
tedbow@omkar.podey thanks, this looks good now. We have a lot of improvements here for handling fixtures!
I will un-postpone #3305564: Create a validator to stop newly installed packages from overwriting existing directories on apply