Problem/Motivation
follow-up to #3335908: The 'fake_site' fixture cannot be using with `composer show` because the packages are not installed
modules/automatic_updates/package_manager/tests/fixtures/path_repos/drupal--core has drupal-scaffold.file_mapping specified that was copied from the pre #3335908 version of package_manager/tests/fixtures/fake_site/vendor/composer/installed.json
Steps to reproduce
Proposed resolution
During \Drupal\automatic_updates\Development\ComposerFixtureCreator::createFixture which is run just when creating updating the fixture at package_manager/tests/fixtures/fake_site and then will be committed to the repo
We should see if we can just copy the file_mapping values from `core/composer.json` to /automatic_updates/package_manager/tests/fixtures/path_repos/drupal--core
We should check how this affects ScaffoldFilePermissionsValidatorTest to ensure we don't lose test coverage and if we need to change/extend coverage
Remaining tasks
User interface changes
API changes
Data model changes
Issue fork automatic_updates-3339714
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 #2
wim leersComment #3
tedbowComment #4
tedbowComment #5
phenaproximaOpened #3340355: [PP-1] Add support for scaffold files that aren't defined by Drupal core or the root composer.json as a follow-up here.
Comment #6
phenaproximaGiven that the scope of this issue, per discussion with @tedbow, only involves the file mapping from drupal/core and the root composer.json, I think it's probably okay if someone who isn't me deals with this.
Comment #7
kunal.sachdev commentedComment #9
tedbowComment #12
kunal.sachdev commentedComment #13
wim leersComment #14
kunal.sachdev commentedComment #15
wim leersDid you try running it locally? The creator of the fixture itself does not have tests, so a green test run is meaningless!
And if I fix that I get
Comment #16
kunal.sachdev commentedIf I run it locally I get
And if I fix that I get
And I also checked the scaffold file mappings, it had copied correct scaffold file mappings.
Comment #17
kunal.sachdev commentedComment #18
wim leerswas wrong of me!
I should've done
I can confirm this works correctly. But what's missing is actually including the results of executing that command in this MR! 😅
Comment #19
kunal.sachdev commentedComment #20
wim leersComment #21
kunal.sachdev commentedComment #22
kunal.sachdev commentedComment #23
wim leers⇒ 🚀
Comment #24
phenaproximaComment #26
phenaproximaLike! Over and out.