aboutsummaryrefslogtreecommitdiffhomepage
path: root/crates/shirabe
diff options
context:
space:
mode:
Diffstat (limited to 'crates/shirabe')
-rw-r--r--crates/shirabe/src/lib.rs167
-rw-r--r--crates/shirabe/tests/advisory/audit_config_test.rs1
-rw-r--r--crates/shirabe/tests/advisory/auditor_test.rs1
-rw-r--r--crates/shirabe/tests/all_functional_test.rs1
-rw-r--r--crates/shirabe/tests/application_test.rs1
-rw-r--r--crates/shirabe/tests/autoload/autoload_generator_test.rs1
-rw-r--r--crates/shirabe/tests/autoload/class_loader_test.rs1
-rw-r--r--crates/shirabe/tests/cache_test.rs1
-rw-r--r--crates/shirabe/tests/cli.rs163
-rw-r--r--crates/shirabe/tests/command/about_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/archive_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/audit_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/base_dependency_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/bump_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/check_platform_reqs_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/clear_cache_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/config_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/diagnose_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/dump_autoload_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/exec_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/fund_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/global_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/home_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/init_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/install_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/licenses_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/reinstall_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/remove_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/repository_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/require_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/run_script_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/search_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/self_update_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/show_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/status_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/suggests_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/update_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/validate_command_test.rs1
-rw-r--r--crates/shirabe/tests/completion_functional_test.rs1
-rw-r--r--crates/shirabe/tests/composer_test.rs1
-rw-r--r--crates/shirabe/tests/config/json_config_source_test.rs1
-rw-r--r--crates/shirabe/tests/config_test.rs1
-rw-r--r--crates/shirabe/tests/console/html_output_formatter_test.rs1
-rw-r--r--crates/shirabe/tests/default_config_test.rs1
-rw-r--r--crates/shirabe/tests/dependency_resolver/default_policy_test.rs1
-rw-r--r--crates/shirabe/tests/dependency_resolver/pool_builder_test.rs1
-rw-r--r--crates/shirabe/tests/dependency_resolver/pool_optimizer_test.rs1
-rw-r--r--crates/shirabe/tests/dependency_resolver/pool_test.rs1
-rw-r--r--crates/shirabe/tests/dependency_resolver/request_test.rs1
-rw-r--r--crates/shirabe/tests/dependency_resolver/rule_set_iterator_test.rs1
-rw-r--r--crates/shirabe/tests/dependency_resolver/rule_set_test.rs1
-rw-r--r--crates/shirabe/tests/dependency_resolver/rule_test.rs1
-rw-r--r--crates/shirabe/tests/dependency_resolver/security_advisory_pool_filter_test.rs1
-rw-r--r--crates/shirabe/tests/dependency_resolver/solver_test.rs1
-rw-r--r--crates/shirabe/tests/dependency_resolver/transaction_test.rs1
-rw-r--r--crates/shirabe/tests/documentation_test.rs1
-rw-r--r--crates/shirabe/tests/downloader/archive_downloader_test.rs1
-rw-r--r--crates/shirabe/tests/downloader/download_manager_test.rs1
-rw-r--r--crates/shirabe/tests/downloader/file_downloader_test.rs1
-rw-r--r--crates/shirabe/tests/downloader/fossil_downloader_test.rs1
-rw-r--r--crates/shirabe/tests/downloader/git_downloader_test.rs1
-rw-r--r--crates/shirabe/tests/downloader/hg_downloader_test.rs1
-rw-r--r--crates/shirabe/tests/downloader/perforce_downloader_test.rs1
-rw-r--r--crates/shirabe/tests/downloader/xz_downloader_test.rs1
-rw-r--r--crates/shirabe/tests/downloader/zip_downloader_test.rs1
-rw-r--r--crates/shirabe/tests/event_dispatcher/event_dispatcher_test.rs1
-rw-r--r--crates/shirabe/tests/factory_test.rs1
-rw-r--r--crates/shirabe/tests/filter/platform_requirement_filter/ignore_all_platform_requirement_filter_test.rs1
-rw-r--r--crates/shirabe/tests/filter/platform_requirement_filter/ignore_list_platform_requirement_filter_test.rs1
-rw-r--r--crates/shirabe/tests/filter/platform_requirement_filter/ignore_nothing_platform_requirement_filter_test.rs1
-rw-r--r--crates/shirabe/tests/filter/platform_requirement_filter/platform_requirement_filter_factory_test.rs1
-rw-r--r--crates/shirabe/tests/installed_versions_test.rs1
-rw-r--r--crates/shirabe/tests/installer/binary_installer_test.rs1
-rw-r--r--crates/shirabe/tests/installer/installation_manager_test.rs1
-rw-r--r--crates/shirabe/tests/installer/installer_event_test.rs1
-rw-r--r--crates/shirabe/tests/installer/library_installer_test.rs1
-rw-r--r--crates/shirabe/tests/installer/metapackage_installer_test.rs1
-rw-r--r--crates/shirabe/tests/installer/suggested_packages_reporter_test.rs1
-rw-r--r--crates/shirabe/tests/installer_test.rs1
-rw-r--r--crates/shirabe/tests/io/buffer_io_test.rs1
-rw-r--r--crates/shirabe/tests/io/console_io_test.rs1
-rw-r--r--crates/shirabe/tests/io/null_io_test.rs1
-rw-r--r--crates/shirabe/tests/json/composer_schema_test.rs1
-rw-r--r--crates/shirabe/tests/json/json_file_test.rs1
-rw-r--r--crates/shirabe/tests/json/json_formatter_test.rs1
-rw-r--r--crates/shirabe/tests/json/json_manipulator_test.rs1
-rw-r--r--crates/shirabe/tests/json/json_validation_exception_test.rs1
-rw-r--r--crates/shirabe/tests/package/archiver/archivable_files_finder_test.rs1
-rw-r--r--crates/shirabe/tests/package/archiver/archive_manager_test.rs1
-rw-r--r--crates/shirabe/tests/package/archiver/git_exclude_filter_test.rs1
-rw-r--r--crates/shirabe/tests/package/archiver/phar_archiver_test.rs1
-rw-r--r--crates/shirabe/tests/package/archiver/zip_archiver_test.rs1
-rw-r--r--crates/shirabe/tests/package/base_package_test.rs1
-rw-r--r--crates/shirabe/tests/package/complete_package_test.rs1
-rw-r--r--crates/shirabe/tests/package/dumper/array_dumper_test.rs1
-rw-r--r--crates/shirabe/tests/package/loader/array_loader_test.rs1
-rw-r--r--crates/shirabe/tests/package/loader/root_package_loader_test.rs1
-rw-r--r--crates/shirabe/tests/package/loader/validating_array_loader_test.rs1
-rw-r--r--crates/shirabe/tests/package/locker_test.rs1
-rw-r--r--crates/shirabe/tests/package/root_alias_package_test.rs1
-rw-r--r--crates/shirabe/tests/package/version/version_bumper_test.rs1
-rw-r--r--crates/shirabe/tests/package/version/version_guesser_test.rs1
-rw-r--r--crates/shirabe/tests/package/version/version_parser_test.rs1
-rw-r--r--crates/shirabe/tests/package/version/version_selector_test.rs1
-rw-r--r--crates/shirabe/tests/platform/hhvm_detector_test.rs1
-rw-r--r--crates/shirabe/tests/platform/runtime_test.rs1
-rw-r--r--crates/shirabe/tests/platform/version_test.rs1
-rw-r--r--crates/shirabe/tests/plugin/plugin_installer_test.rs1
-rw-r--r--crates/shirabe/tests/question/strict_confirmation_question_test.rs1
-rw-r--r--crates/shirabe/tests/repository/array_repository_test.rs1
-rw-r--r--crates/shirabe/tests/repository/artifact_repository_test.rs1
-rw-r--r--crates/shirabe/tests/repository/composer_repository_test.rs1
-rw-r--r--crates/shirabe/tests/repository/composite_repository_test.rs1
-rw-r--r--crates/shirabe/tests/repository/filesystem_repository_test.rs1
-rw-r--r--crates/shirabe/tests/repository/filter_repository_test.rs1
-rw-r--r--crates/shirabe/tests/repository/installed_repository_test.rs1
-rw-r--r--crates/shirabe/tests/repository/path_repository_test.rs1
-rw-r--r--crates/shirabe/tests/repository/platform_repository_test.rs1
-rw-r--r--crates/shirabe/tests/repository/repository_factory_test.rs1
-rw-r--r--crates/shirabe/tests/repository/repository_manager_test.rs1
-rw-r--r--crates/shirabe/tests/repository/repository_utils_test.rs1
-rw-r--r--crates/shirabe/tests/repository/vcs/forgejo_driver_test.rs1
-rw-r--r--crates/shirabe/tests/repository/vcs/fossil_driver_test.rs1
-rw-r--r--crates/shirabe/tests/repository/vcs/git_bitbucket_driver_test.rs1
-rw-r--r--crates/shirabe/tests/repository/vcs/git_driver_test.rs1
-rw-r--r--crates/shirabe/tests/repository/vcs/github_driver_test.rs1
-rw-r--r--crates/shirabe/tests/repository/vcs/gitlab_driver_test.rs1
-rw-r--r--crates/shirabe/tests/repository/vcs/hg_driver_test.rs1
-rw-r--r--crates/shirabe/tests/repository/vcs/perforce_driver_test.rs1
-rw-r--r--crates/shirabe/tests/repository/vcs/svn_driver_test.rs1
-rw-r--r--crates/shirabe/tests/repository/vcs_repository_test.rs1
-rw-r--r--crates/shirabe/tests/script/event_test.rs1
-rw-r--r--crates/shirabe/tests/util/auth_helper_test.rs1
-rw-r--r--crates/shirabe/tests/util/bitbucket_test.rs1
-rw-r--r--crates/shirabe/tests/util/config_validator_test.rs1
-rw-r--r--crates/shirabe/tests/util/error_handler_test.rs1
-rw-r--r--crates/shirabe/tests/util/filesystem_test.rs1
-rw-r--r--crates/shirabe/tests/util/forgejo_test.rs1
-rw-r--r--crates/shirabe/tests/util/forgejo_url_test.rs1
-rw-r--r--crates/shirabe/tests/util/git_test.rs1
-rw-r--r--crates/shirabe/tests/util/github_test.rs1
-rw-r--r--crates/shirabe/tests/util/gitlab_test.rs1
-rw-r--r--crates/shirabe/tests/util/http/proxy_item_test.rs1
-rw-r--r--crates/shirabe/tests/util/http/proxy_manager_test.rs1
-rw-r--r--crates/shirabe/tests/util/http/request_proxy_test.rs1
-rw-r--r--crates/shirabe/tests/util/http_downloader_test.rs1
-rw-r--r--crates/shirabe/tests/util/ini_helper_test.rs1
-rw-r--r--crates/shirabe/tests/util/metadata_minifier_test.rs1
-rw-r--r--crates/shirabe/tests/util/no_proxy_pattern_test.rs1
-rw-r--r--crates/shirabe/tests/util/package_sorter_test.rs1
-rw-r--r--crates/shirabe/tests/util/perforce_test.rs1
-rw-r--r--crates/shirabe/tests/util/platform_test.rs1
-rw-r--r--crates/shirabe/tests/util/process_executor_test.rs1
-rw-r--r--crates/shirabe/tests/util/remote_filesystem_test.rs1
-rw-r--r--crates/shirabe/tests/util/silencer_test.rs1
-rw-r--r--crates/shirabe/tests/util/stream_context_factory_test.rs1
-rw-r--r--crates/shirabe/tests/util/svn_test.rs1
-rw-r--r--crates/shirabe/tests/util/tar_test.rs1
-rw-r--r--crates/shirabe/tests/util/tls_helper_test.rs1
-rw-r--r--crates/shirabe/tests/util/url_test.rs1
-rw-r--r--crates/shirabe/tests/util/zip_test.rs1
161 files changed, 326 insertions, 163 deletions
diff --git a/crates/shirabe/src/lib.rs b/crates/shirabe/src/lib.rs
index 4bd52c2..8d8cc96 100644
--- a/crates/shirabe/src/lib.rs
+++ b/crates/shirabe/src/lib.rs
@@ -44,3 +44,170 @@ pub fn run(argv: Vec<String>) -> anyhow::Result<i32> {
as std::rc::Rc<std::cell::RefCell<dyn InputInterface>>;
Application::run(&application, Some(input), None)
}
+
+#[cfg(test)]
+mod cli_tests {
+ use std::panic::{AssertUnwindSafe, catch_unwind};
+ use std::sync::{Mutex, Once};
+
+ const COMMANDS: &[&str] = &[
+ "about",
+ "archive",
+ "audit",
+ "browse",
+ "bump",
+ "check-platform-reqs",
+ "clear-cache",
+ "config",
+ "create-project",
+ "depends",
+ "diagnose",
+ "dump-autoload",
+ "exec",
+ "fund",
+ "global",
+ "init",
+ "install",
+ "licenses",
+ "outdated",
+ "prohibits",
+ "reinstall",
+ "remove",
+ "repository",
+ "require",
+ "run-script",
+ "search",
+ "self-update",
+ "show",
+ "status",
+ "suggests",
+ "update",
+ "validate",
+ ];
+
+ static QUIET_PANIC: Once = Once::new();
+
+ /// `crate::run` reads/writes process-global env, so concurrent invocations race;
+ /// serialize them since the default test harness runs tests on many threads.
+ static SERIAL: Mutex<()> = Mutex::new(());
+
+ /// Runs the CLI with `args`. Returns true on clean exit, false on any panic / error / non-zero
+ /// exit.
+ fn run(args: &[&str]) -> bool {
+ QUIET_PANIC.call_once(|| std::panic::set_hook(Box::new(|_| {})));
+ let _guard = SERIAL.lock().unwrap_or_else(|e| e.into_inner());
+
+ // Each invocation must look like a fresh process.
+ //
+ // SAFETY: all environment access in these tests happens through `crate::run` while holding
+ // `SERIAL`, so no other thread reads or writes the environment concurrently with these calls.
+ unsafe {
+ std::env::remove_var("COLUMNS");
+ std::env::remove_var("LINES");
+ }
+
+ let mut argv = vec!["composer".to_string()];
+ argv.extend(args.iter().map(|s| s.to_string()));
+ matches!(
+ catch_unwind(AssertUnwindSafe(|| crate::run(argv))),
+ Ok(Ok(0))
+ )
+ }
+
+ #[test]
+ fn version_flag() {
+ assert!(run(&["--version"]));
+ }
+
+ #[test]
+ fn help_flag() {
+ assert!(run(&["--help"]));
+ }
+
+ #[test]
+ fn each_command_help() {
+ let failed: Vec<&&str> = COMMANDS.iter().filter(|c| !run(&[c, "--help"])).collect();
+ assert!(failed.is_empty(), "`<cmd> --help` failed for: {failed:?}");
+ }
+
+ /// Runs the CLI with `args` from inside an empty temporary directory. Returns true if the call did
+ /// not panic (any exit code, including non-zero or an `Err` return, counts as success).
+ fn run_no_panic(args: &[&str]) -> bool {
+ QUIET_PANIC.call_once(|| std::panic::set_hook(Box::new(|_| {})));
+ let _guard = SERIAL.lock().unwrap_or_else(|e| e.into_inner());
+
+ let original = std::env::current_dir().ok();
+ let dir = tempfile::tempdir().expect("create temp dir");
+ std::env::set_current_dir(dir.path()).expect("chdir to temp dir");
+
+ // SAFETY: all environment access here happens while holding `SERIAL`, so no other thread
+ // touches the environment or working directory concurrently.
+ unsafe {
+ std::env::remove_var("COLUMNS");
+ std::env::remove_var("LINES");
+ }
+
+ let mut argv = vec!["composer".to_string()];
+ argv.extend(args.iter().map(|s| s.to_string()));
+ let result = catch_unwind(AssertUnwindSafe(|| crate::run(argv)));
+
+ if let Some(orig) = original {
+ let _ = std::env::set_current_dir(orig);
+ }
+
+ result.is_ok()
+ }
+
+ macro_rules! run_no_panic_tests {
+ ($( $(#[$attr:meta])* $name:ident => $cmd:expr ),* $(,)?) => {
+ $(
+ $(#[$attr])*
+ #[test]
+ fn $name() {
+ assert!(run_no_panic(&[$cmd]), "`{}` panicked", $cmd);
+ }
+ )*
+ };
+ }
+
+ run_no_panic_tests! {
+ run_about => "about",
+ #[ignore = "currently panics"]
+ run_archive => "archive",
+ run_audit => "audit",
+ #[ignore = "currently panics"]
+ run_browse => "browse",
+ run_bump => "bump",
+ run_check_platform_reqs => "check-platform-reqs",
+ #[ignore = "currently panics"]
+ run_clear_cache => "clear-cache",
+ run_config => "config",
+ run_create_project => "create-project",
+ run_depends => "depends",
+ #[ignore = "currently panics"]
+ run_diagnose => "diagnose",
+ run_dump_autoload => "dump-autoload",
+ run_exec => "exec",
+ run_fund => "fund",
+ run_global => "global",
+ #[ignore = "currently panics"]
+ run_init => "init",
+ run_install => "install",
+ run_licenses => "licenses",
+ run_outdated => "outdated",
+ run_prohibits => "prohibits",
+ run_reinstall => "reinstall",
+ run_remove => "remove",
+ run_repository => "repository",
+ #[ignore = "currently panics"]
+ run_require => "require",
+ run_run_script => "run-script",
+ run_search => "search",
+ run_self_update => "self-update",
+ run_show => "show",
+ run_status => "status",
+ run_suggests => "suggests",
+ run_update => "update",
+ run_validate => "validate",
+ }
+}
diff --git a/crates/shirabe/tests/advisory/audit_config_test.rs b/crates/shirabe/tests/advisory/audit_config_test.rs
new file mode 100644
index 0000000..6a86a30
--- /dev/null
+++ b/crates/shirabe/tests/advisory/audit_config_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Advisory/AuditConfigTest.php
diff --git a/crates/shirabe/tests/advisory/auditor_test.rs b/crates/shirabe/tests/advisory/auditor_test.rs
new file mode 100644
index 0000000..8c6fafe
--- /dev/null
+++ b/crates/shirabe/tests/advisory/auditor_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Advisory/AuditorTest.php
diff --git a/crates/shirabe/tests/all_functional_test.rs b/crates/shirabe/tests/all_functional_test.rs
new file mode 100644
index 0000000..88ab725
--- /dev/null
+++ b/crates/shirabe/tests/all_functional_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/AllFunctionalTest.php
diff --git a/crates/shirabe/tests/application_test.rs b/crates/shirabe/tests/application_test.rs
new file mode 100644
index 0000000..5f3e07c
--- /dev/null
+++ b/crates/shirabe/tests/application_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/ApplicationTest.php
diff --git a/crates/shirabe/tests/autoload/autoload_generator_test.rs b/crates/shirabe/tests/autoload/autoload_generator_test.rs
new file mode 100644
index 0000000..68d3848
--- /dev/null
+++ b/crates/shirabe/tests/autoload/autoload_generator_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Autoload/AutoloadGeneratorTest.php
diff --git a/crates/shirabe/tests/autoload/class_loader_test.rs b/crates/shirabe/tests/autoload/class_loader_test.rs
new file mode 100644
index 0000000..02fb48f
--- /dev/null
+++ b/crates/shirabe/tests/autoload/class_loader_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Autoload/ClassLoaderTest.php
diff --git a/crates/shirabe/tests/cache_test.rs b/crates/shirabe/tests/cache_test.rs
new file mode 100644
index 0000000..c03f42b
--- /dev/null
+++ b/crates/shirabe/tests/cache_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/CacheTest.php
diff --git a/crates/shirabe/tests/cli.rs b/crates/shirabe/tests/cli.rs
deleted file mode 100644
index c77dd01..0000000
--- a/crates/shirabe/tests/cli.rs
+++ /dev/null
@@ -1,163 +0,0 @@
-use std::panic::{AssertUnwindSafe, catch_unwind};
-use std::sync::{Mutex, Once};
-
-const COMMANDS: &[&str] = &[
- "about",
- "archive",
- "audit",
- "browse",
- "bump",
- "check-platform-reqs",
- "clear-cache",
- "config",
- "create-project",
- "depends",
- "diagnose",
- "dump-autoload",
- "exec",
- "fund",
- "global",
- "init",
- "install",
- "licenses",
- "outdated",
- "prohibits",
- "reinstall",
- "remove",
- "repository",
- "require",
- "run-script",
- "search",
- "self-update",
- "show",
- "status",
- "suggests",
- "update",
- "validate",
-];
-
-static QUIET_PANIC: Once = Once::new();
-
-/// `shirabe::run` reads/writes process-global env, so concurrent invocations race;
-/// serialize them since the default test harness runs tests on many threads.
-static SERIAL: Mutex<()> = Mutex::new(());
-
-/// Runs the CLI with `args`. Returns true on clean exit, false on any panic / error / non-zero
-/// exit.
-fn run(args: &[&str]) -> bool {
- QUIET_PANIC.call_once(|| std::panic::set_hook(Box::new(|_| {})));
- let _guard = SERIAL.lock().unwrap_or_else(|e| e.into_inner());
-
- // Each invocation must look like a fresh process.
- //
- // SAFETY: all environment access in these tests happens through `shirabe::run` while holding
- // `SERIAL`, so no other thread reads or writes the environment concurrently with these calls.
- unsafe {
- std::env::remove_var("COLUMNS");
- std::env::remove_var("LINES");
- }
-
- let mut argv = vec!["composer".to_string()];
- argv.extend(args.iter().map(|s| s.to_string()));
- matches!(
- catch_unwind(AssertUnwindSafe(|| shirabe::run(argv))),
- Ok(Ok(0))
- )
-}
-
-#[test]
-fn version_flag() {
- assert!(run(&["--version"]));
-}
-
-#[test]
-fn help_flag() {
- assert!(run(&["--help"]));
-}
-
-#[test]
-fn each_command_help() {
- let failed: Vec<&&str> = COMMANDS.iter().filter(|c| !run(&[c, "--help"])).collect();
- assert!(failed.is_empty(), "`<cmd> --help` failed for: {failed:?}");
-}
-
-/// Runs the CLI with `args` from inside an empty temporary directory. Returns true if the call did
-/// not panic (any exit code, including non-zero or an `Err` return, counts as success).
-fn run_no_panic(args: &[&str]) -> bool {
- QUIET_PANIC.call_once(|| std::panic::set_hook(Box::new(|_| {})));
- let _guard = SERIAL.lock().unwrap_or_else(|e| e.into_inner());
-
- let original = std::env::current_dir().ok();
- let dir = tempfile::tempdir().expect("create temp dir");
- std::env::set_current_dir(dir.path()).expect("chdir to temp dir");
-
- // SAFETY: all environment access here happens while holding `SERIAL`, so no other thread
- // touches the environment or working directory concurrently.
- unsafe {
- std::env::remove_var("COLUMNS");
- std::env::remove_var("LINES");
- }
-
- let mut argv = vec!["composer".to_string()];
- argv.extend(args.iter().map(|s| s.to_string()));
- let result = catch_unwind(AssertUnwindSafe(|| shirabe::run(argv)));
-
- if let Some(orig) = original {
- let _ = std::env::set_current_dir(orig);
- }
-
- result.is_ok()
-}
-
-macro_rules! run_no_panic_tests {
- ($( $(#[$attr:meta])* $name:ident => $cmd:expr ),* $(,)?) => {
- $(
- $(#[$attr])*
- #[test]
- fn $name() {
- assert!(run_no_panic(&[$cmd]), "`{}` panicked", $cmd);
- }
- )*
- };
-}
-
-run_no_panic_tests! {
- run_about => "about",
- #[ignore = "currently panics"]
- run_archive => "archive",
- run_audit => "audit",
- #[ignore = "currently panics"]
- run_browse => "browse",
- run_bump => "bump",
- run_check_platform_reqs => "check-platform-reqs",
- #[ignore = "currently panics"]
- run_clear_cache => "clear-cache",
- run_config => "config",
- run_create_project => "create-project",
- run_depends => "depends",
- #[ignore = "currently panics"]
- run_diagnose => "diagnose",
- run_dump_autoload => "dump-autoload",
- run_exec => "exec",
- run_fund => "fund",
- run_global => "global",
- #[ignore = "currently panics"]
- run_init => "init",
- run_install => "install",
- run_licenses => "licenses",
- run_outdated => "outdated",
- run_prohibits => "prohibits",
- run_reinstall => "reinstall",
- run_remove => "remove",
- run_repository => "repository",
- #[ignore = "currently panics"]
- run_require => "require",
- run_run_script => "run-script",
- run_search => "search",
- run_self_update => "self-update",
- run_show => "show",
- run_status => "status",
- run_suggests => "suggests",
- run_update => "update",
- run_validate => "validate",
-}
diff --git a/crates/shirabe/tests/command/about_command_test.rs b/crates/shirabe/tests/command/about_command_test.rs
new file mode 100644
index 0000000..e1817f3
--- /dev/null
+++ b/crates/shirabe/tests/command/about_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/AboutCommandTest.php
diff --git a/crates/shirabe/tests/command/archive_command_test.rs b/crates/shirabe/tests/command/archive_command_test.rs
new file mode 100644
index 0000000..79e0a8b
--- /dev/null
+++ b/crates/shirabe/tests/command/archive_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/ArchiveCommandTest.php
diff --git a/crates/shirabe/tests/command/audit_command_test.rs b/crates/shirabe/tests/command/audit_command_test.rs
new file mode 100644
index 0000000..fd18db1
--- /dev/null
+++ b/crates/shirabe/tests/command/audit_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/AuditCommandTest.php
diff --git a/crates/shirabe/tests/command/base_dependency_command_test.rs b/crates/shirabe/tests/command/base_dependency_command_test.rs
new file mode 100644
index 0000000..d6ac4d7
--- /dev/null
+++ b/crates/shirabe/tests/command/base_dependency_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/BaseDependencyCommandTest.php
diff --git a/crates/shirabe/tests/command/bump_command_test.rs b/crates/shirabe/tests/command/bump_command_test.rs
new file mode 100644
index 0000000..3478643
--- /dev/null
+++ b/crates/shirabe/tests/command/bump_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/BumpCommandTest.php
diff --git a/crates/shirabe/tests/command/check_platform_reqs_command_test.rs b/crates/shirabe/tests/command/check_platform_reqs_command_test.rs
new file mode 100644
index 0000000..f54b78e
--- /dev/null
+++ b/crates/shirabe/tests/command/check_platform_reqs_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/CheckPlatformReqsCommandTest.php
diff --git a/crates/shirabe/tests/command/clear_cache_command_test.rs b/crates/shirabe/tests/command/clear_cache_command_test.rs
new file mode 100644
index 0000000..29eb90e
--- /dev/null
+++ b/crates/shirabe/tests/command/clear_cache_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/ClearCacheCommandTest.php
diff --git a/crates/shirabe/tests/command/config_command_test.rs b/crates/shirabe/tests/command/config_command_test.rs
new file mode 100644
index 0000000..f7a3a96
--- /dev/null
+++ b/crates/shirabe/tests/command/config_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/ConfigCommandTest.php
diff --git a/crates/shirabe/tests/command/diagnose_command_test.rs b/crates/shirabe/tests/command/diagnose_command_test.rs
new file mode 100644
index 0000000..0ed56d3
--- /dev/null
+++ b/crates/shirabe/tests/command/diagnose_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/DiagnoseCommandTest.php
diff --git a/crates/shirabe/tests/command/dump_autoload_command_test.rs b/crates/shirabe/tests/command/dump_autoload_command_test.rs
new file mode 100644
index 0000000..0335e98
--- /dev/null
+++ b/crates/shirabe/tests/command/dump_autoload_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/DumpAutoloadCommandTest.php
diff --git a/crates/shirabe/tests/command/exec_command_test.rs b/crates/shirabe/tests/command/exec_command_test.rs
new file mode 100644
index 0000000..59ac4d6
--- /dev/null
+++ b/crates/shirabe/tests/command/exec_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/ExecCommandTest.php
diff --git a/crates/shirabe/tests/command/fund_command_test.rs b/crates/shirabe/tests/command/fund_command_test.rs
new file mode 100644
index 0000000..d4bf441
--- /dev/null
+++ b/crates/shirabe/tests/command/fund_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/FundCommandTest.php
diff --git a/crates/shirabe/tests/command/global_command_test.rs b/crates/shirabe/tests/command/global_command_test.rs
new file mode 100644
index 0000000..63ad32e
--- /dev/null
+++ b/crates/shirabe/tests/command/global_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/GlobalCommandTest.php
diff --git a/crates/shirabe/tests/command/home_command_test.rs b/crates/shirabe/tests/command/home_command_test.rs
new file mode 100644
index 0000000..0cbe03d
--- /dev/null
+++ b/crates/shirabe/tests/command/home_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/HomeCommandTest.php
diff --git a/crates/shirabe/tests/command/init_command_test.rs b/crates/shirabe/tests/command/init_command_test.rs
new file mode 100644
index 0000000..9108496
--- /dev/null
+++ b/crates/shirabe/tests/command/init_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/InitCommandTest.php
diff --git a/crates/shirabe/tests/command/install_command_test.rs b/crates/shirabe/tests/command/install_command_test.rs
new file mode 100644
index 0000000..44c0df7
--- /dev/null
+++ b/crates/shirabe/tests/command/install_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/InstallCommandTest.php
diff --git a/crates/shirabe/tests/command/licenses_command_test.rs b/crates/shirabe/tests/command/licenses_command_test.rs
new file mode 100644
index 0000000..7b3c44f
--- /dev/null
+++ b/crates/shirabe/tests/command/licenses_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/LicensesCommandTest.php
diff --git a/crates/shirabe/tests/command/reinstall_command_test.rs b/crates/shirabe/tests/command/reinstall_command_test.rs
new file mode 100644
index 0000000..3cf6712
--- /dev/null
+++ b/crates/shirabe/tests/command/reinstall_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/ReinstallCommandTest.php
diff --git a/crates/shirabe/tests/command/remove_command_test.rs b/crates/shirabe/tests/command/remove_command_test.rs
new file mode 100644
index 0000000..d2b26a4
--- /dev/null
+++ b/crates/shirabe/tests/command/remove_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/RemoveCommandTest.php
diff --git a/crates/shirabe/tests/command/repository_command_test.rs b/crates/shirabe/tests/command/repository_command_test.rs
new file mode 100644
index 0000000..52ee7ec
--- /dev/null
+++ b/crates/shirabe/tests/command/repository_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/RepositoryCommandTest.php
diff --git a/crates/shirabe/tests/command/require_command_test.rs b/crates/shirabe/tests/command/require_command_test.rs
new file mode 100644
index 0000000..2201745
--- /dev/null
+++ b/crates/shirabe/tests/command/require_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/RequireCommandTest.php
diff --git a/crates/shirabe/tests/command/run_script_command_test.rs b/crates/shirabe/tests/command/run_script_command_test.rs
new file mode 100644
index 0000000..9ae8c5f
--- /dev/null
+++ b/crates/shirabe/tests/command/run_script_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/RunScriptCommandTest.php
diff --git a/crates/shirabe/tests/command/search_command_test.rs b/crates/shirabe/tests/command/search_command_test.rs
new file mode 100644
index 0000000..a6fdb1c
--- /dev/null
+++ b/crates/shirabe/tests/command/search_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/SearchCommandTest.php
diff --git a/crates/shirabe/tests/command/self_update_command_test.rs b/crates/shirabe/tests/command/self_update_command_test.rs
new file mode 100644
index 0000000..6623853
--- /dev/null
+++ b/crates/shirabe/tests/command/self_update_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/SelfUpdateCommandTest.php
diff --git a/crates/shirabe/tests/command/show_command_test.rs b/crates/shirabe/tests/command/show_command_test.rs
new file mode 100644
index 0000000..932dc3a
--- /dev/null
+++ b/crates/shirabe/tests/command/show_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/ShowCommandTest.php
diff --git a/crates/shirabe/tests/command/status_command_test.rs b/crates/shirabe/tests/command/status_command_test.rs
new file mode 100644
index 0000000..8dec3eb
--- /dev/null
+++ b/crates/shirabe/tests/command/status_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/StatusCommandTest.php
diff --git a/crates/shirabe/tests/command/suggests_command_test.rs b/crates/shirabe/tests/command/suggests_command_test.rs
new file mode 100644
index 0000000..857535a
--- /dev/null
+++ b/crates/shirabe/tests/command/suggests_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/SuggestsCommandTest.php
diff --git a/crates/shirabe/tests/command/update_command_test.rs b/crates/shirabe/tests/command/update_command_test.rs
new file mode 100644
index 0000000..180c90f
--- /dev/null
+++ b/crates/shirabe/tests/command/update_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/UpdateCommandTest.php
diff --git a/crates/shirabe/tests/command/validate_command_test.rs b/crates/shirabe/tests/command/validate_command_test.rs
new file mode 100644
index 0000000..0d10cc5
--- /dev/null
+++ b/crates/shirabe/tests/command/validate_command_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Command/ValidateCommandTest.php
diff --git a/crates/shirabe/tests/completion_functional_test.rs b/crates/shirabe/tests/completion_functional_test.rs
new file mode 100644
index 0000000..9411721
--- /dev/null
+++ b/crates/shirabe/tests/completion_functional_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/CompletionFunctionalTest.php
diff --git a/crates/shirabe/tests/composer_test.rs b/crates/shirabe/tests/composer_test.rs
new file mode 100644
index 0000000..40fd139
--- /dev/null
+++ b/crates/shirabe/tests/composer_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/ComposerTest.php
diff --git a/crates/shirabe/tests/config/json_config_source_test.rs b/crates/shirabe/tests/config/json_config_source_test.rs
new file mode 100644
index 0000000..7ae61ca
--- /dev/null
+++ b/crates/shirabe/tests/config/json_config_source_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Config/JsonConfigSourceTest.php
diff --git a/crates/shirabe/tests/config_test.rs b/crates/shirabe/tests/config_test.rs
new file mode 100644
index 0000000..ed806cf
--- /dev/null
+++ b/crates/shirabe/tests/config_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/ConfigTest.php
diff --git a/crates/shirabe/tests/console/html_output_formatter_test.rs b/crates/shirabe/tests/console/html_output_formatter_test.rs
new file mode 100644
index 0000000..e3b65d9
--- /dev/null
+++ b/crates/shirabe/tests/console/html_output_formatter_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Console/HtmlOutputFormatterTest.php
diff --git a/crates/shirabe/tests/default_config_test.rs b/crates/shirabe/tests/default_config_test.rs
new file mode 100644
index 0000000..61e3a2d
--- /dev/null
+++ b/crates/shirabe/tests/default_config_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/DefaultConfigTest.php
diff --git a/crates/shirabe/tests/dependency_resolver/default_policy_test.rs b/crates/shirabe/tests/dependency_resolver/default_policy_test.rs
new file mode 100644
index 0000000..898ca01
--- /dev/null
+++ b/crates/shirabe/tests/dependency_resolver/default_policy_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/DependencyResolver/DefaultPolicyTest.php
diff --git a/crates/shirabe/tests/dependency_resolver/pool_builder_test.rs b/crates/shirabe/tests/dependency_resolver/pool_builder_test.rs
new file mode 100644
index 0000000..2290f45
--- /dev/null
+++ b/crates/shirabe/tests/dependency_resolver/pool_builder_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/DependencyResolver/PoolBuilderTest.php
diff --git a/crates/shirabe/tests/dependency_resolver/pool_optimizer_test.rs b/crates/shirabe/tests/dependency_resolver/pool_optimizer_test.rs
new file mode 100644
index 0000000..bf7592e
--- /dev/null
+++ b/crates/shirabe/tests/dependency_resolver/pool_optimizer_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/DependencyResolver/PoolOptimizerTest.php
diff --git a/crates/shirabe/tests/dependency_resolver/pool_test.rs b/crates/shirabe/tests/dependency_resolver/pool_test.rs
new file mode 100644
index 0000000..3efd85b
--- /dev/null
+++ b/crates/shirabe/tests/dependency_resolver/pool_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/DependencyResolver/PoolTest.php
diff --git a/crates/shirabe/tests/dependency_resolver/request_test.rs b/crates/shirabe/tests/dependency_resolver/request_test.rs
new file mode 100644
index 0000000..9a211a7
--- /dev/null
+++ b/crates/shirabe/tests/dependency_resolver/request_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/DependencyResolver/RequestTest.php
diff --git a/crates/shirabe/tests/dependency_resolver/rule_set_iterator_test.rs b/crates/shirabe/tests/dependency_resolver/rule_set_iterator_test.rs
new file mode 100644
index 0000000..73cff8e
--- /dev/null
+++ b/crates/shirabe/tests/dependency_resolver/rule_set_iterator_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/DependencyResolver/RuleSetIteratorTest.php
diff --git a/crates/shirabe/tests/dependency_resolver/rule_set_test.rs b/crates/shirabe/tests/dependency_resolver/rule_set_test.rs
new file mode 100644
index 0000000..c78bd03
--- /dev/null
+++ b/crates/shirabe/tests/dependency_resolver/rule_set_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/DependencyResolver/RuleSetTest.php
diff --git a/crates/shirabe/tests/dependency_resolver/rule_test.rs b/crates/shirabe/tests/dependency_resolver/rule_test.rs
new file mode 100644
index 0000000..69d4816
--- /dev/null
+++ b/crates/shirabe/tests/dependency_resolver/rule_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/DependencyResolver/RuleTest.php
diff --git a/crates/shirabe/tests/dependency_resolver/security_advisory_pool_filter_test.rs b/crates/shirabe/tests/dependency_resolver/security_advisory_pool_filter_test.rs
new file mode 100644
index 0000000..d002fd8
--- /dev/null
+++ b/crates/shirabe/tests/dependency_resolver/security_advisory_pool_filter_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/DependencyResolver/SecurityAdvisoryPoolFilterTest.php
diff --git a/crates/shirabe/tests/dependency_resolver/solver_test.rs b/crates/shirabe/tests/dependency_resolver/solver_test.rs
new file mode 100644
index 0000000..30f7957
--- /dev/null
+++ b/crates/shirabe/tests/dependency_resolver/solver_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/DependencyResolver/SolverTest.php
diff --git a/crates/shirabe/tests/dependency_resolver/transaction_test.rs b/crates/shirabe/tests/dependency_resolver/transaction_test.rs
new file mode 100644
index 0000000..68c1049
--- /dev/null
+++ b/crates/shirabe/tests/dependency_resolver/transaction_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/DependencyResolver/TransactionTest.php
diff --git a/crates/shirabe/tests/documentation_test.rs b/crates/shirabe/tests/documentation_test.rs
new file mode 100644
index 0000000..d341a93
--- /dev/null
+++ b/crates/shirabe/tests/documentation_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/DocumentationTest.php
diff --git a/crates/shirabe/tests/downloader/archive_downloader_test.rs b/crates/shirabe/tests/downloader/archive_downloader_test.rs
new file mode 100644
index 0000000..54ac321
--- /dev/null
+++ b/crates/shirabe/tests/downloader/archive_downloader_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Downloader/ArchiveDownloaderTest.php
diff --git a/crates/shirabe/tests/downloader/download_manager_test.rs b/crates/shirabe/tests/downloader/download_manager_test.rs
new file mode 100644
index 0000000..b13420b
--- /dev/null
+++ b/crates/shirabe/tests/downloader/download_manager_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Downloader/DownloadManagerTest.php
diff --git a/crates/shirabe/tests/downloader/file_downloader_test.rs b/crates/shirabe/tests/downloader/file_downloader_test.rs
new file mode 100644
index 0000000..54afad4
--- /dev/null
+++ b/crates/shirabe/tests/downloader/file_downloader_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Downloader/FileDownloaderTest.php
diff --git a/crates/shirabe/tests/downloader/fossil_downloader_test.rs b/crates/shirabe/tests/downloader/fossil_downloader_test.rs
new file mode 100644
index 0000000..827d634
--- /dev/null
+++ b/crates/shirabe/tests/downloader/fossil_downloader_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Downloader/FossilDownloaderTest.php
diff --git a/crates/shirabe/tests/downloader/git_downloader_test.rs b/crates/shirabe/tests/downloader/git_downloader_test.rs
new file mode 100644
index 0000000..3c30177
--- /dev/null
+++ b/crates/shirabe/tests/downloader/git_downloader_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Downloader/GitDownloaderTest.php
diff --git a/crates/shirabe/tests/downloader/hg_downloader_test.rs b/crates/shirabe/tests/downloader/hg_downloader_test.rs
new file mode 100644
index 0000000..bf08c1a
--- /dev/null
+++ b/crates/shirabe/tests/downloader/hg_downloader_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Downloader/HgDownloaderTest.php
diff --git a/crates/shirabe/tests/downloader/perforce_downloader_test.rs b/crates/shirabe/tests/downloader/perforce_downloader_test.rs
new file mode 100644
index 0000000..97f45ca
--- /dev/null
+++ b/crates/shirabe/tests/downloader/perforce_downloader_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Downloader/PerforceDownloaderTest.php
diff --git a/crates/shirabe/tests/downloader/xz_downloader_test.rs b/crates/shirabe/tests/downloader/xz_downloader_test.rs
new file mode 100644
index 0000000..33a34ae
--- /dev/null
+++ b/crates/shirabe/tests/downloader/xz_downloader_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Downloader/XzDownloaderTest.php
diff --git a/crates/shirabe/tests/downloader/zip_downloader_test.rs b/crates/shirabe/tests/downloader/zip_downloader_test.rs
new file mode 100644
index 0000000..8b53dac
--- /dev/null
+++ b/crates/shirabe/tests/downloader/zip_downloader_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Downloader/ZipDownloaderTest.php
diff --git a/crates/shirabe/tests/event_dispatcher/event_dispatcher_test.rs b/crates/shirabe/tests/event_dispatcher/event_dispatcher_test.rs
new file mode 100644
index 0000000..1194da4
--- /dev/null
+++ b/crates/shirabe/tests/event_dispatcher/event_dispatcher_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/EventDispatcher/EventDispatcherTest.php
diff --git a/crates/shirabe/tests/factory_test.rs b/crates/shirabe/tests/factory_test.rs
new file mode 100644
index 0000000..a7ad372
--- /dev/null
+++ b/crates/shirabe/tests/factory_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/FactoryTest.php
diff --git a/crates/shirabe/tests/filter/platform_requirement_filter/ignore_all_platform_requirement_filter_test.rs b/crates/shirabe/tests/filter/platform_requirement_filter/ignore_all_platform_requirement_filter_test.rs
new file mode 100644
index 0000000..cd34d0e
--- /dev/null
+++ b/crates/shirabe/tests/filter/platform_requirement_filter/ignore_all_platform_requirement_filter_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Filter/PlatformRequirementFilter/IgnoreAllPlatformRequirementFilterTest.php
diff --git a/crates/shirabe/tests/filter/platform_requirement_filter/ignore_list_platform_requirement_filter_test.rs b/crates/shirabe/tests/filter/platform_requirement_filter/ignore_list_platform_requirement_filter_test.rs
new file mode 100644
index 0000000..be3ca1a
--- /dev/null
+++ b/crates/shirabe/tests/filter/platform_requirement_filter/ignore_list_platform_requirement_filter_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Filter/PlatformRequirementFilter/IgnoreListPlatformRequirementFilterTest.php
diff --git a/crates/shirabe/tests/filter/platform_requirement_filter/ignore_nothing_platform_requirement_filter_test.rs b/crates/shirabe/tests/filter/platform_requirement_filter/ignore_nothing_platform_requirement_filter_test.rs
new file mode 100644
index 0000000..d7c23e7
--- /dev/null
+++ b/crates/shirabe/tests/filter/platform_requirement_filter/ignore_nothing_platform_requirement_filter_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Filter/PlatformRequirementFilter/IgnoreNothingPlatformRequirementFilterTest.php
diff --git a/crates/shirabe/tests/filter/platform_requirement_filter/platform_requirement_filter_factory_test.rs b/crates/shirabe/tests/filter/platform_requirement_filter/platform_requirement_filter_factory_test.rs
new file mode 100644
index 0000000..f8230a4
--- /dev/null
+++ b/crates/shirabe/tests/filter/platform_requirement_filter/platform_requirement_filter_factory_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Filter/PlatformRequirementFilter/PlatformRequirementFilterFactoryTest.php
diff --git a/crates/shirabe/tests/installed_versions_test.rs b/crates/shirabe/tests/installed_versions_test.rs
new file mode 100644
index 0000000..3173559
--- /dev/null
+++ b/crates/shirabe/tests/installed_versions_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/InstalledVersionsTest.php
diff --git a/crates/shirabe/tests/installer/binary_installer_test.rs b/crates/shirabe/tests/installer/binary_installer_test.rs
new file mode 100644
index 0000000..06a2e91
--- /dev/null
+++ b/crates/shirabe/tests/installer/binary_installer_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Installer/BinaryInstallerTest.php
diff --git a/crates/shirabe/tests/installer/installation_manager_test.rs b/crates/shirabe/tests/installer/installation_manager_test.rs
new file mode 100644
index 0000000..66d89ed
--- /dev/null
+++ b/crates/shirabe/tests/installer/installation_manager_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Installer/InstallationManagerTest.php
diff --git a/crates/shirabe/tests/installer/installer_event_test.rs b/crates/shirabe/tests/installer/installer_event_test.rs
new file mode 100644
index 0000000..9144488
--- /dev/null
+++ b/crates/shirabe/tests/installer/installer_event_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Installer/InstallerEventTest.php
diff --git a/crates/shirabe/tests/installer/library_installer_test.rs b/crates/shirabe/tests/installer/library_installer_test.rs
new file mode 100644
index 0000000..e15a225
--- /dev/null
+++ b/crates/shirabe/tests/installer/library_installer_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Installer/LibraryInstallerTest.php
diff --git a/crates/shirabe/tests/installer/metapackage_installer_test.rs b/crates/shirabe/tests/installer/metapackage_installer_test.rs
new file mode 100644
index 0000000..29f8526
--- /dev/null
+++ b/crates/shirabe/tests/installer/metapackage_installer_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Installer/MetapackageInstallerTest.php
diff --git a/crates/shirabe/tests/installer/suggested_packages_reporter_test.rs b/crates/shirabe/tests/installer/suggested_packages_reporter_test.rs
new file mode 100644
index 0000000..4d672f6
--- /dev/null
+++ b/crates/shirabe/tests/installer/suggested_packages_reporter_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Installer/SuggestedPackagesReporterTest.php
diff --git a/crates/shirabe/tests/installer_test.rs b/crates/shirabe/tests/installer_test.rs
new file mode 100644
index 0000000..2376d47
--- /dev/null
+++ b/crates/shirabe/tests/installer_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/InstallerTest.php
diff --git a/crates/shirabe/tests/io/buffer_io_test.rs b/crates/shirabe/tests/io/buffer_io_test.rs
new file mode 100644
index 0000000..c3e9876
--- /dev/null
+++ b/crates/shirabe/tests/io/buffer_io_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/IO/BufferIOTest.php
diff --git a/crates/shirabe/tests/io/console_io_test.rs b/crates/shirabe/tests/io/console_io_test.rs
new file mode 100644
index 0000000..be2ce85
--- /dev/null
+++ b/crates/shirabe/tests/io/console_io_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/IO/ConsoleIOTest.php
diff --git a/crates/shirabe/tests/io/null_io_test.rs b/crates/shirabe/tests/io/null_io_test.rs
new file mode 100644
index 0000000..78ae3ec
--- /dev/null
+++ b/crates/shirabe/tests/io/null_io_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/IO/NullIOTest.php
diff --git a/crates/shirabe/tests/json/composer_schema_test.rs b/crates/shirabe/tests/json/composer_schema_test.rs
new file mode 100644
index 0000000..abf310f
--- /dev/null
+++ b/crates/shirabe/tests/json/composer_schema_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Json/ComposerSchemaTest.php
diff --git a/crates/shirabe/tests/json/json_file_test.rs b/crates/shirabe/tests/json/json_file_test.rs
new file mode 100644
index 0000000..99793ef
--- /dev/null
+++ b/crates/shirabe/tests/json/json_file_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Json/JsonFileTest.php
diff --git a/crates/shirabe/tests/json/json_formatter_test.rs b/crates/shirabe/tests/json/json_formatter_test.rs
new file mode 100644
index 0000000..78eb01b
--- /dev/null
+++ b/crates/shirabe/tests/json/json_formatter_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Json/JsonFormatterTest.php
diff --git a/crates/shirabe/tests/json/json_manipulator_test.rs b/crates/shirabe/tests/json/json_manipulator_test.rs
new file mode 100644
index 0000000..491646b
--- /dev/null
+++ b/crates/shirabe/tests/json/json_manipulator_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Json/JsonManipulatorTest.php
diff --git a/crates/shirabe/tests/json/json_validation_exception_test.rs b/crates/shirabe/tests/json/json_validation_exception_test.rs
new file mode 100644
index 0000000..12620ba
--- /dev/null
+++ b/crates/shirabe/tests/json/json_validation_exception_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Json/JsonValidationExceptionTest.php
diff --git a/crates/shirabe/tests/package/archiver/archivable_files_finder_test.rs b/crates/shirabe/tests/package/archiver/archivable_files_finder_test.rs
new file mode 100644
index 0000000..7513284
--- /dev/null
+++ b/crates/shirabe/tests/package/archiver/archivable_files_finder_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/Archiver/ArchivableFilesFinderTest.php
diff --git a/crates/shirabe/tests/package/archiver/archive_manager_test.rs b/crates/shirabe/tests/package/archiver/archive_manager_test.rs
new file mode 100644
index 0000000..c4c9775
--- /dev/null
+++ b/crates/shirabe/tests/package/archiver/archive_manager_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/Archiver/ArchiveManagerTest.php
diff --git a/crates/shirabe/tests/package/archiver/git_exclude_filter_test.rs b/crates/shirabe/tests/package/archiver/git_exclude_filter_test.rs
new file mode 100644
index 0000000..63374c4
--- /dev/null
+++ b/crates/shirabe/tests/package/archiver/git_exclude_filter_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/Archiver/GitExcludeFilterTest.php
diff --git a/crates/shirabe/tests/package/archiver/phar_archiver_test.rs b/crates/shirabe/tests/package/archiver/phar_archiver_test.rs
new file mode 100644
index 0000000..a1de919
--- /dev/null
+++ b/crates/shirabe/tests/package/archiver/phar_archiver_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/Archiver/PharArchiverTest.php
diff --git a/crates/shirabe/tests/package/archiver/zip_archiver_test.rs b/crates/shirabe/tests/package/archiver/zip_archiver_test.rs
new file mode 100644
index 0000000..b24679b
--- /dev/null
+++ b/crates/shirabe/tests/package/archiver/zip_archiver_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/Archiver/ZipArchiverTest.php
diff --git a/crates/shirabe/tests/package/base_package_test.rs b/crates/shirabe/tests/package/base_package_test.rs
new file mode 100644
index 0000000..d6b9a0e
--- /dev/null
+++ b/crates/shirabe/tests/package/base_package_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/BasePackageTest.php
diff --git a/crates/shirabe/tests/package/complete_package_test.rs b/crates/shirabe/tests/package/complete_package_test.rs
new file mode 100644
index 0000000..b47a4aa
--- /dev/null
+++ b/crates/shirabe/tests/package/complete_package_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/CompletePackageTest.php
diff --git a/crates/shirabe/tests/package/dumper/array_dumper_test.rs b/crates/shirabe/tests/package/dumper/array_dumper_test.rs
new file mode 100644
index 0000000..a6647c1
--- /dev/null
+++ b/crates/shirabe/tests/package/dumper/array_dumper_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/Dumper/ArrayDumperTest.php
diff --git a/crates/shirabe/tests/package/loader/array_loader_test.rs b/crates/shirabe/tests/package/loader/array_loader_test.rs
new file mode 100644
index 0000000..a241722
--- /dev/null
+++ b/crates/shirabe/tests/package/loader/array_loader_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/Loader/ArrayLoaderTest.php
diff --git a/crates/shirabe/tests/package/loader/root_package_loader_test.rs b/crates/shirabe/tests/package/loader/root_package_loader_test.rs
new file mode 100644
index 0000000..6aee231
--- /dev/null
+++ b/crates/shirabe/tests/package/loader/root_package_loader_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/Loader/RootPackageLoaderTest.php
diff --git a/crates/shirabe/tests/package/loader/validating_array_loader_test.rs b/crates/shirabe/tests/package/loader/validating_array_loader_test.rs
new file mode 100644
index 0000000..b974397
--- /dev/null
+++ b/crates/shirabe/tests/package/loader/validating_array_loader_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/Loader/ValidatingArrayLoaderTest.php
diff --git a/crates/shirabe/tests/package/locker_test.rs b/crates/shirabe/tests/package/locker_test.rs
new file mode 100644
index 0000000..6bfc8bc
--- /dev/null
+++ b/crates/shirabe/tests/package/locker_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/LockerTest.php
diff --git a/crates/shirabe/tests/package/root_alias_package_test.rs b/crates/shirabe/tests/package/root_alias_package_test.rs
new file mode 100644
index 0000000..fe97919
--- /dev/null
+++ b/crates/shirabe/tests/package/root_alias_package_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/RootAliasPackageTest.php
diff --git a/crates/shirabe/tests/package/version/version_bumper_test.rs b/crates/shirabe/tests/package/version/version_bumper_test.rs
new file mode 100644
index 0000000..1c9f82f
--- /dev/null
+++ b/crates/shirabe/tests/package/version/version_bumper_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/Version/VersionBumperTest.php
diff --git a/crates/shirabe/tests/package/version/version_guesser_test.rs b/crates/shirabe/tests/package/version/version_guesser_test.rs
new file mode 100644
index 0000000..4f91b89
--- /dev/null
+++ b/crates/shirabe/tests/package/version/version_guesser_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/Version/VersionGuesserTest.php
diff --git a/crates/shirabe/tests/package/version/version_parser_test.rs b/crates/shirabe/tests/package/version/version_parser_test.rs
new file mode 100644
index 0000000..b8a7a81
--- /dev/null
+++ b/crates/shirabe/tests/package/version/version_parser_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/Version/VersionParserTest.php
diff --git a/crates/shirabe/tests/package/version/version_selector_test.rs b/crates/shirabe/tests/package/version/version_selector_test.rs
new file mode 100644
index 0000000..a97ae4b
--- /dev/null
+++ b/crates/shirabe/tests/package/version/version_selector_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Package/Version/VersionSelectorTest.php
diff --git a/crates/shirabe/tests/platform/hhvm_detector_test.rs b/crates/shirabe/tests/platform/hhvm_detector_test.rs
new file mode 100644
index 0000000..11cb28c
--- /dev/null
+++ b/crates/shirabe/tests/platform/hhvm_detector_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Platform/HhvmDetectorTest.php
diff --git a/crates/shirabe/tests/platform/runtime_test.rs b/crates/shirabe/tests/platform/runtime_test.rs
new file mode 100644
index 0000000..1fbb628
--- /dev/null
+++ b/crates/shirabe/tests/platform/runtime_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Platform/RuntimeTest.php
diff --git a/crates/shirabe/tests/platform/version_test.rs b/crates/shirabe/tests/platform/version_test.rs
new file mode 100644
index 0000000..fc247f6
--- /dev/null
+++ b/crates/shirabe/tests/platform/version_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Platform/VersionTest.php
diff --git a/crates/shirabe/tests/plugin/plugin_installer_test.rs b/crates/shirabe/tests/plugin/plugin_installer_test.rs
new file mode 100644
index 0000000..767a478
--- /dev/null
+++ b/crates/shirabe/tests/plugin/plugin_installer_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Plugin/PluginInstallerTest.php
diff --git a/crates/shirabe/tests/question/strict_confirmation_question_test.rs b/crates/shirabe/tests/question/strict_confirmation_question_test.rs
new file mode 100644
index 0000000..e5a3299
--- /dev/null
+++ b/crates/shirabe/tests/question/strict_confirmation_question_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Question/StrictConfirmationQuestionTest.php
diff --git a/crates/shirabe/tests/repository/array_repository_test.rs b/crates/shirabe/tests/repository/array_repository_test.rs
new file mode 100644
index 0000000..a239eff
--- /dev/null
+++ b/crates/shirabe/tests/repository/array_repository_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/ArrayRepositoryTest.php
diff --git a/crates/shirabe/tests/repository/artifact_repository_test.rs b/crates/shirabe/tests/repository/artifact_repository_test.rs
new file mode 100644
index 0000000..cda2044
--- /dev/null
+++ b/crates/shirabe/tests/repository/artifact_repository_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/ArtifactRepositoryTest.php
diff --git a/crates/shirabe/tests/repository/composer_repository_test.rs b/crates/shirabe/tests/repository/composer_repository_test.rs
new file mode 100644
index 0000000..627027a
--- /dev/null
+++ b/crates/shirabe/tests/repository/composer_repository_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/ComposerRepositoryTest.php
diff --git a/crates/shirabe/tests/repository/composite_repository_test.rs b/crates/shirabe/tests/repository/composite_repository_test.rs
new file mode 100644
index 0000000..cc8ddf2
--- /dev/null
+++ b/crates/shirabe/tests/repository/composite_repository_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/CompositeRepositoryTest.php
diff --git a/crates/shirabe/tests/repository/filesystem_repository_test.rs b/crates/shirabe/tests/repository/filesystem_repository_test.rs
new file mode 100644
index 0000000..83f879d
--- /dev/null
+++ b/crates/shirabe/tests/repository/filesystem_repository_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/FilesystemRepositoryTest.php
diff --git a/crates/shirabe/tests/repository/filter_repository_test.rs b/crates/shirabe/tests/repository/filter_repository_test.rs
new file mode 100644
index 0000000..bbb46c5
--- /dev/null
+++ b/crates/shirabe/tests/repository/filter_repository_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/FilterRepositoryTest.php
diff --git a/crates/shirabe/tests/repository/installed_repository_test.rs b/crates/shirabe/tests/repository/installed_repository_test.rs
new file mode 100644
index 0000000..510923a
--- /dev/null
+++ b/crates/shirabe/tests/repository/installed_repository_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/InstalledRepositoryTest.php
diff --git a/crates/shirabe/tests/repository/path_repository_test.rs b/crates/shirabe/tests/repository/path_repository_test.rs
new file mode 100644
index 0000000..93ef6bf
--- /dev/null
+++ b/crates/shirabe/tests/repository/path_repository_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/PathRepositoryTest.php
diff --git a/crates/shirabe/tests/repository/platform_repository_test.rs b/crates/shirabe/tests/repository/platform_repository_test.rs
new file mode 100644
index 0000000..d4028b1
--- /dev/null
+++ b/crates/shirabe/tests/repository/platform_repository_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/PlatformRepositoryTest.php
diff --git a/crates/shirabe/tests/repository/repository_factory_test.rs b/crates/shirabe/tests/repository/repository_factory_test.rs
new file mode 100644
index 0000000..b878449
--- /dev/null
+++ b/crates/shirabe/tests/repository/repository_factory_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/RepositoryFactoryTest.php
diff --git a/crates/shirabe/tests/repository/repository_manager_test.rs b/crates/shirabe/tests/repository/repository_manager_test.rs
new file mode 100644
index 0000000..6af58e8
--- /dev/null
+++ b/crates/shirabe/tests/repository/repository_manager_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/RepositoryManagerTest.php
diff --git a/crates/shirabe/tests/repository/repository_utils_test.rs b/crates/shirabe/tests/repository/repository_utils_test.rs
new file mode 100644
index 0000000..b732b42
--- /dev/null
+++ b/crates/shirabe/tests/repository/repository_utils_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/RepositoryUtilsTest.php
diff --git a/crates/shirabe/tests/repository/vcs/forgejo_driver_test.rs b/crates/shirabe/tests/repository/vcs/forgejo_driver_test.rs
new file mode 100644
index 0000000..9b9760a
--- /dev/null
+++ b/crates/shirabe/tests/repository/vcs/forgejo_driver_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/Vcs/ForgejoDriverTest.php
diff --git a/crates/shirabe/tests/repository/vcs/fossil_driver_test.rs b/crates/shirabe/tests/repository/vcs/fossil_driver_test.rs
new file mode 100644
index 0000000..9cfb4a7
--- /dev/null
+++ b/crates/shirabe/tests/repository/vcs/fossil_driver_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/Vcs/FossilDriverTest.php
diff --git a/crates/shirabe/tests/repository/vcs/git_bitbucket_driver_test.rs b/crates/shirabe/tests/repository/vcs/git_bitbucket_driver_test.rs
new file mode 100644
index 0000000..2c6d427
--- /dev/null
+++ b/crates/shirabe/tests/repository/vcs/git_bitbucket_driver_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/Vcs/GitBitbucketDriverTest.php
diff --git a/crates/shirabe/tests/repository/vcs/git_driver_test.rs b/crates/shirabe/tests/repository/vcs/git_driver_test.rs
new file mode 100644
index 0000000..c915947
--- /dev/null
+++ b/crates/shirabe/tests/repository/vcs/git_driver_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/Vcs/GitDriverTest.php
diff --git a/crates/shirabe/tests/repository/vcs/github_driver_test.rs b/crates/shirabe/tests/repository/vcs/github_driver_test.rs
new file mode 100644
index 0000000..fd27768
--- /dev/null
+++ b/crates/shirabe/tests/repository/vcs/github_driver_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/Vcs/GitHubDriverTest.php
diff --git a/crates/shirabe/tests/repository/vcs/gitlab_driver_test.rs b/crates/shirabe/tests/repository/vcs/gitlab_driver_test.rs
new file mode 100644
index 0000000..7543394
--- /dev/null
+++ b/crates/shirabe/tests/repository/vcs/gitlab_driver_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/Vcs/GitLabDriverTest.php
diff --git a/crates/shirabe/tests/repository/vcs/hg_driver_test.rs b/crates/shirabe/tests/repository/vcs/hg_driver_test.rs
new file mode 100644
index 0000000..30be485
--- /dev/null
+++ b/crates/shirabe/tests/repository/vcs/hg_driver_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/Vcs/HgDriverTest.php
diff --git a/crates/shirabe/tests/repository/vcs/perforce_driver_test.rs b/crates/shirabe/tests/repository/vcs/perforce_driver_test.rs
new file mode 100644
index 0000000..68e251f
--- /dev/null
+++ b/crates/shirabe/tests/repository/vcs/perforce_driver_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/Vcs/PerforceDriverTest.php
diff --git a/crates/shirabe/tests/repository/vcs/svn_driver_test.rs b/crates/shirabe/tests/repository/vcs/svn_driver_test.rs
new file mode 100644
index 0000000..ad85dc7
--- /dev/null
+++ b/crates/shirabe/tests/repository/vcs/svn_driver_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/Vcs/SvnDriverTest.php
diff --git a/crates/shirabe/tests/repository/vcs_repository_test.rs b/crates/shirabe/tests/repository/vcs_repository_test.rs
new file mode 100644
index 0000000..a830f0e
--- /dev/null
+++ b/crates/shirabe/tests/repository/vcs_repository_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Repository/VcsRepositoryTest.php
diff --git a/crates/shirabe/tests/script/event_test.rs b/crates/shirabe/tests/script/event_test.rs
new file mode 100644
index 0000000..47891c7
--- /dev/null
+++ b/crates/shirabe/tests/script/event_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Script/EventTest.php
diff --git a/crates/shirabe/tests/util/auth_helper_test.rs b/crates/shirabe/tests/util/auth_helper_test.rs
new file mode 100644
index 0000000..9ff7446
--- /dev/null
+++ b/crates/shirabe/tests/util/auth_helper_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/AuthHelperTest.php
diff --git a/crates/shirabe/tests/util/bitbucket_test.rs b/crates/shirabe/tests/util/bitbucket_test.rs
new file mode 100644
index 0000000..43cd2a4
--- /dev/null
+++ b/crates/shirabe/tests/util/bitbucket_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/BitbucketTest.php
diff --git a/crates/shirabe/tests/util/config_validator_test.rs b/crates/shirabe/tests/util/config_validator_test.rs
new file mode 100644
index 0000000..8aa46a7
--- /dev/null
+++ b/crates/shirabe/tests/util/config_validator_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/ConfigValidatorTest.php
diff --git a/crates/shirabe/tests/util/error_handler_test.rs b/crates/shirabe/tests/util/error_handler_test.rs
new file mode 100644
index 0000000..3fecc60
--- /dev/null
+++ b/crates/shirabe/tests/util/error_handler_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/ErrorHandlerTest.php
diff --git a/crates/shirabe/tests/util/filesystem_test.rs b/crates/shirabe/tests/util/filesystem_test.rs
new file mode 100644
index 0000000..16ffd3c
--- /dev/null
+++ b/crates/shirabe/tests/util/filesystem_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/FilesystemTest.php
diff --git a/crates/shirabe/tests/util/forgejo_test.rs b/crates/shirabe/tests/util/forgejo_test.rs
new file mode 100644
index 0000000..9965d36
--- /dev/null
+++ b/crates/shirabe/tests/util/forgejo_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/ForgejoTest.php
diff --git a/crates/shirabe/tests/util/forgejo_url_test.rs b/crates/shirabe/tests/util/forgejo_url_test.rs
new file mode 100644
index 0000000..970578e
--- /dev/null
+++ b/crates/shirabe/tests/util/forgejo_url_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/ForgejoUrlTest.php
diff --git a/crates/shirabe/tests/util/git_test.rs b/crates/shirabe/tests/util/git_test.rs
new file mode 100644
index 0000000..f8cf3d7
--- /dev/null
+++ b/crates/shirabe/tests/util/git_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/GitTest.php
diff --git a/crates/shirabe/tests/util/github_test.rs b/crates/shirabe/tests/util/github_test.rs
new file mode 100644
index 0000000..9a3271a
--- /dev/null
+++ b/crates/shirabe/tests/util/github_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/GitHubTest.php
diff --git a/crates/shirabe/tests/util/gitlab_test.rs b/crates/shirabe/tests/util/gitlab_test.rs
new file mode 100644
index 0000000..2f42f47
--- /dev/null
+++ b/crates/shirabe/tests/util/gitlab_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/GitLabTest.php
diff --git a/crates/shirabe/tests/util/http/proxy_item_test.rs b/crates/shirabe/tests/util/http/proxy_item_test.rs
new file mode 100644
index 0000000..2c2be9e
--- /dev/null
+++ b/crates/shirabe/tests/util/http/proxy_item_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/Http/ProxyItemTest.php
diff --git a/crates/shirabe/tests/util/http/proxy_manager_test.rs b/crates/shirabe/tests/util/http/proxy_manager_test.rs
new file mode 100644
index 0000000..a37c45b
--- /dev/null
+++ b/crates/shirabe/tests/util/http/proxy_manager_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/Http/ProxyManagerTest.php
diff --git a/crates/shirabe/tests/util/http/request_proxy_test.rs b/crates/shirabe/tests/util/http/request_proxy_test.rs
new file mode 100644
index 0000000..37da071
--- /dev/null
+++ b/crates/shirabe/tests/util/http/request_proxy_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/Http/RequestProxyTest.php
diff --git a/crates/shirabe/tests/util/http_downloader_test.rs b/crates/shirabe/tests/util/http_downloader_test.rs
new file mode 100644
index 0000000..e7fcb7b
--- /dev/null
+++ b/crates/shirabe/tests/util/http_downloader_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/HttpDownloaderTest.php
diff --git a/crates/shirabe/tests/util/ini_helper_test.rs b/crates/shirabe/tests/util/ini_helper_test.rs
new file mode 100644
index 0000000..69f6f1b
--- /dev/null
+++ b/crates/shirabe/tests/util/ini_helper_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/IniHelperTest.php
diff --git a/crates/shirabe/tests/util/metadata_minifier_test.rs b/crates/shirabe/tests/util/metadata_minifier_test.rs
new file mode 100644
index 0000000..7caa7ae
--- /dev/null
+++ b/crates/shirabe/tests/util/metadata_minifier_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/MetadataMinifierTest.php
diff --git a/crates/shirabe/tests/util/no_proxy_pattern_test.rs b/crates/shirabe/tests/util/no_proxy_pattern_test.rs
new file mode 100644
index 0000000..82e0ae7
--- /dev/null
+++ b/crates/shirabe/tests/util/no_proxy_pattern_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/NoProxyPatternTest.php
diff --git a/crates/shirabe/tests/util/package_sorter_test.rs b/crates/shirabe/tests/util/package_sorter_test.rs
new file mode 100644
index 0000000..a162ac8
--- /dev/null
+++ b/crates/shirabe/tests/util/package_sorter_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/PackageSorterTest.php
diff --git a/crates/shirabe/tests/util/perforce_test.rs b/crates/shirabe/tests/util/perforce_test.rs
new file mode 100644
index 0000000..3a1a5a3
--- /dev/null
+++ b/crates/shirabe/tests/util/perforce_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/PerforceTest.php
diff --git a/crates/shirabe/tests/util/platform_test.rs b/crates/shirabe/tests/util/platform_test.rs
new file mode 100644
index 0000000..90ce6ad
--- /dev/null
+++ b/crates/shirabe/tests/util/platform_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/PlatformTest.php
diff --git a/crates/shirabe/tests/util/process_executor_test.rs b/crates/shirabe/tests/util/process_executor_test.rs
new file mode 100644
index 0000000..6b30c9d
--- /dev/null
+++ b/crates/shirabe/tests/util/process_executor_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/ProcessExecutorTest.php
diff --git a/crates/shirabe/tests/util/remote_filesystem_test.rs b/crates/shirabe/tests/util/remote_filesystem_test.rs
new file mode 100644
index 0000000..ffd1744
--- /dev/null
+++ b/crates/shirabe/tests/util/remote_filesystem_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/RemoteFilesystemTest.php
diff --git a/crates/shirabe/tests/util/silencer_test.rs b/crates/shirabe/tests/util/silencer_test.rs
new file mode 100644
index 0000000..8152b6e
--- /dev/null
+++ b/crates/shirabe/tests/util/silencer_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/SilencerTest.php
diff --git a/crates/shirabe/tests/util/stream_context_factory_test.rs b/crates/shirabe/tests/util/stream_context_factory_test.rs
new file mode 100644
index 0000000..4c18a09
--- /dev/null
+++ b/crates/shirabe/tests/util/stream_context_factory_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/StreamContextFactoryTest.php
diff --git a/crates/shirabe/tests/util/svn_test.rs b/crates/shirabe/tests/util/svn_test.rs
new file mode 100644
index 0000000..65cbeca
--- /dev/null
+++ b/crates/shirabe/tests/util/svn_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/SvnTest.php
diff --git a/crates/shirabe/tests/util/tar_test.rs b/crates/shirabe/tests/util/tar_test.rs
new file mode 100644
index 0000000..6bba0b5
--- /dev/null
+++ b/crates/shirabe/tests/util/tar_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/TarTest.php
diff --git a/crates/shirabe/tests/util/tls_helper_test.rs b/crates/shirabe/tests/util/tls_helper_test.rs
new file mode 100644
index 0000000..13abf77
--- /dev/null
+++ b/crates/shirabe/tests/util/tls_helper_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/TlsHelperTest.php
diff --git a/crates/shirabe/tests/util/url_test.rs b/crates/shirabe/tests/util/url_test.rs
new file mode 100644
index 0000000..d900457
--- /dev/null
+++ b/crates/shirabe/tests/util/url_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/UrlTest.php
diff --git a/crates/shirabe/tests/util/zip_test.rs b/crates/shirabe/tests/util/zip_test.rs
new file mode 100644
index 0000000..2d85522
--- /dev/null
+++ b/crates/shirabe/tests/util/zip_test.rs
@@ -0,0 +1 @@
+//! ref: composer/tests/Composer/Test/Util/ZipTest.php