From c1733d88510b7afb88f7a17849de514365e42c84 Mon Sep 17 00:00:00 2001 From: nsfisis Date: Sat, 2 May 2026 16:53:41 +0900 Subject: refactor(registry): introduce Repository and InstallerExecutor traits Sets up DI scaffolding for in-process installer E2E tests, mirroring how Composer's PHPUnit suite swaps Packagist (FactoryMock) and the install manager (InstallationManagerMock) without touching the network or filesystem. Additions: - Repository trait + RepositorySet (Composer's RepositoryInterface analog), with PackagistRepository, InlinePackageRepository, VcsRepository impls. - InstallerExecutor trait (Composer's InstallationManager analog) with FilesystemExecutor extracted from install_from_lock. install_from_lock now delegates per-package install/uninstall verbs to FilesystemExecutor; console output orchestration stays in the caller so existing --EXPECT-OUTPUT-shape assertions remain comparable. No behavior change - all 136 enabled installer fixtures still pass. Also tightens the installer_fixture\! ignore form to a single token (installer_fixture\!(name, ignore)) for readability. Co-Authored-By: Claude Opus 4.7 (1M context) --- Cargo.lock | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'Cargo.lock') diff --git a/Cargo.lock b/Cargo.lock index d1ae1cb..890314b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -97,6 +97,17 @@ dependencies = [ "wait-timeout", ] +[[package]] +name = "async-trait" +version = "0.1.89" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9035ad2d096bed7955a320ee7e2230574d28fd3c3a0f186cbea1ff3c7eed5dbb" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "atomic-waker" version = "1.1.2" @@ -1170,6 +1181,7 @@ name = "mozart-registry" version = "0.1.0" dependencies = [ "anyhow", + "async-trait", "filetime", "flate2", "md5", -- cgit v1.3.1