aboutsummaryrefslogtreecommitdiffhomepage
path: root/crates/mozart/tests/installer.rs
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2026-05-03 21:23:37 +0900
committernsfisis <nsfisis@gmail.com>2026-05-03 21:23:37 +0900
commit577bd35f97fd46ad5f296980c86f5fcc51413f5c (patch)
tree715d60517780e379c5e41e5792da280cbfc75644 /crates/mozart/tests/installer.rs
parent6ec10b18cfe2e473d71f8d786ae0d6a9877864ab (diff)
downloadphp-mozart-577bd35f97fd46ad5f296980c86f5fcc51413f5c.tar.gz
php-mozart-577bd35f97fd46ad5f296980c86f5fcc51413f5c.tar.zst
php-mozart-577bd35f97fd46ad5f296980c86f5fcc51413f5c.zip
fix(update): mirror Composer's always-include-dev resolution path
Composer's `Installer::doUpdate` hardcodes `includeDevRequires=true` for the first solve, so a `--no-dev` update still considers require-dev during resolution and writes a complete lock file (the flag only gates what gets installed). Mozart was passing `include_dev: dev_mode`, dropping require-dev from both the resolver pool and the lock when `--no-dev` was set, which broke fixtures where a non-dev requirement was satisfied by a package pulled in transitively through require-dev (e.g. `provided/pkg` provided by a require-dev metapackage). Also extend `classify_dev_packages` to walk `provide`/`replace` edges so the production BFS reaches packages that satisfy a `require` virtually, matching what Composer's `extractDevPackages` second-Solver run achieves through a real solve.
Diffstat (limited to 'crates/mozart/tests/installer.rs')
-rw-r--r--crates/mozart/tests/installer.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/mozart/tests/installer.rs b/crates/mozart/tests/installer.rs
index 06c7581..fd8ab73 100644
--- a/crates/mozart/tests/installer.rs
+++ b/crates/mozart/tests/installer.rs
@@ -311,7 +311,7 @@ installer_fixture!(provider_can_coexist_with_other_version_of_provided);
installer_fixture!(provider_conflicts);
installer_fixture!(provider_conflicts2);
installer_fixture!(provider_conflicts3);
-installer_fixture!(provider_dev_require_can_satisfy_require, ignore);
+installer_fixture!(provider_dev_require_can_satisfy_require);
installer_fixture!(provider_gets_picked_together_with_other_version_of_provided);
installer_fixture!(
provider_gets_picked_together_with_other_version_of_provided_conflict,