aboutsummaryrefslogtreecommitdiffhomepage
path: root/crates
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2026-08-12 01:20:33 +0900
committernsfisis <nsfisis@gmail.com>2026-08-12 01:20:33 +0900
commit3e2613f70ebdb441269556d1080a69a1f21a4f7d (patch)
treec1f60a8d5deb5518506d7d59674c953957dc0990 /crates
parent0779bfe8c7b5ee22034d552477cac54e8ae2895f (diff)
downloadphp-shirabe-3e2613f70ebdb441269556d1080a69a1f21a4f7d.tar.gz
php-shirabe-3e2613f70ebdb441269556d1080a69a1f21a4f7d.tar.zst
php-shirabe-3e2613f70ebdb441269556d1080a69a1f21a4f7d.zip
test: drop stale #[ignore]s and rewrite the run-script reasons
Measuring every ignored test with `cargo test --workspace --no-fail-fast -- --ignored` turned up 11 that pass today; their reasons named todo!()s and gaps that have since been implemented. The two run_script_command_test cases still fail, but not for the reason given: the user's Command class is imported and executed, and what is missing is only a way to observe it, since PhpCommandProxy::run forwards the run to the worker-side console application. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Diffstat (limited to 'crates')
-rw-r--r--crates/shirabe/tests/all_functional_test.rs6
-rw-r--r--crates/shirabe/tests/application_test.rs6
-rw-r--r--crates/shirabe/tests/autoload/autoload_generator_test.rs6
-rw-r--r--crates/shirabe/tests/command/base_dependency_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/global_command_test.rs1
-rw-r--r--crates/shirabe/tests/command/run_script_command_test.rs12
-rw-r--r--crates/shirabe/tests/package/loader/root_package_loader_test.rs1
7 files changed, 10 insertions, 23 deletions
diff --git a/crates/shirabe/tests/all_functional_test.rs b/crates/shirabe/tests/all_functional_test.rs
index a05a575a..f9059927 100644
--- a/crates/shirabe/tests/all_functional_test.rs
+++ b/crates/shirabe/tests/all_functional_test.rs
@@ -259,11 +259,6 @@ fn test_integration_create_project_command() {
#[test]
#[serial]
-#[ignore = "needs live network (real git clone from github.com). The two former in-process \
- blockers are fixed: the scheme-less packages.json read via RemoteFilesystem::\
- get_remote_contents, and the exit-101 panic during CreateProjectCommand's keep-vcs \
- cleanup, whose Symfony Finder name patterns go through Glob::to_regex (now \
- regex-crate-compatible); a full green run is unverified because it requires network"]
fn test_integration_create_project_shows_full_hash_for_dev_packages() {
run_integration("create-project-shows-full-hash-for-dev-packages.test");
}
@@ -284,7 +279,6 @@ fn test_integration_installed_versions2() {
#[test]
#[serial]
-#[ignore = "requires the Plugin API (PHP plugins emitting !! markers), which is not yet implemented"]
fn test_integration_plugin_autoloading_only_loads_dependencies() {
run_integration("plugin-autoloading-only-loads-dependencies.test");
}
diff --git a/crates/shirabe/tests/application_test.rs b/crates/shirabe/tests/application_test.rs
index 257bc861..1c93b790 100644
--- a/crates/shirabe/tests/application_test.rs
+++ b/crates/shirabe/tests/application_test.rs
@@ -145,9 +145,6 @@ fn test_process_isolation_works_multiple_times() {
assert_eq!(0, application.do_run(input2, output2).unwrap());
}
-#[ignore = "Application::do_run registers the composer.json script as a command, a path that ends at a todo!() \
- (application.rs:2461, 'plugin: register reflection-instantiated command on Application::add'). With a \
- 'scripts' key present, do_run panics there before getComposer is reached"]
#[test]
#[serial]
fn test_no_plugins_disables_plugins_when_script_commands_exist() {
@@ -213,9 +210,6 @@ fn test_no_plugins_disables_plugins_when_script_commands_exist() {
);
}
-#[ignore = "Application::do_run registers composer.json scripts as commands; that path ends at a todo!() \
- (application.rs:2461, 'plugin: register reflection-instantiated command on Application::add'). With a \
- 'scripts' key present, do_run panics there before the script command executes"]
#[test]
#[serial]
fn test_script_command_takes_priority_over_abbreviated_builtin_command() {
diff --git a/crates/shirabe/tests/autoload/autoload_generator_test.rs b/crates/shirabe/tests/autoload/autoload_generator_test.rs
index e55635fc..3f2c142c 100644
--- a/crates/shirabe/tests/autoload/autoload_generator_test.rs
+++ b/crates/shirabe/tests/autoload/autoload_generator_test.rs
@@ -935,7 +935,6 @@ fn test_non_dev_autoload_replaces_nested_requirements() {
#[test]
#[serial]
-#[ignore = "autoload_static.php getInitializer() fixture has a trailing blank line the current AutoloadGenerator template omits; needs production template alignment"]
fn test_phar_autoload() {
let mut s = set_up();
let package = new_root_pkg("root/a");
@@ -1381,7 +1380,6 @@ fn test_class_map_autoloading_authoritative_and_apcu_prefix() {
#[test]
#[serial]
-#[ignore = "autoload_real.php/autoload_static.php fixtures track a newer Composer template (single blank lines + $filesToLoad/$requireFile block) than the current AutoloadGenerator port emits; needs production template alignment"]
fn test_files_autoload_generation() {
let mut s = set_up();
let package = new_root_pkg("root/a");
@@ -1651,7 +1649,6 @@ fn test_empty_paths() {
#[test]
#[serial]
-#[ignore = "fixture assumes the symlinked composersrc/foo/bar tree (created via `ln -s` in PHP) and exercises exclude-from-classmap pattern matching that the port does not yet apply; symlink setup not replicated"]
fn test_exclude_from_classmap() {
let mut s = set_up();
let package = new_root_pkg("root/a");
@@ -2106,7 +2103,6 @@ fn test_vendor_dir_excluded_from_working_dir() {
#[test]
#[serial]
-#[ignore = "classmap generation does not apply exclude-from-classmap rules that use up-level (../) relative paths or wildcards, so excluded classes (Boo/Boo2/Boo3/Boo4) still appear"]
fn test_up_level_relative_paths() {
let mut s = set_up();
let working_dir = format!("{}/working-dir", s.working_dir);
@@ -2514,7 +2510,6 @@ fn test_generates_platform_check() {
#[test]
#[serial]
-#[ignore = "psr-4 compliance warning is emitted for files reached through an absolute symlink; Composer does not warn here"]
fn test_absolute_symlink_with_psr4_does_not_generate_warnings() {
let mut s = set_up();
let package = new_root_pkg("test/package");
@@ -2552,7 +2547,6 @@ fn test_absolute_symlink_with_psr4_does_not_generate_warnings() {
#[test]
#[serial]
-#[ignore = "exclude-from-classmap '**/vendor/' is not applied to paths reached through an absolute symlink, so PHPUnit\\Framework\\Exception is not excluded"]
fn test_absolute_symlink_with_classmap_exclude_from_classmap() {
let mut s = set_up();
let package = new_root_pkg("test/package");
diff --git a/crates/shirabe/tests/command/base_dependency_command_test.rs b/crates/shirabe/tests/command/base_dependency_command_test.rs
index 41ad362d..ace43ae7 100644
--- a/crates/shirabe/tests/command/base_dependency_command_test.rs
+++ b/crates/shirabe/tests/command/base_dependency_command_test.rs
@@ -445,7 +445,6 @@ fn test_why_command_outputs() {
/// ref: BaseDependencyCommandTest::testWhyNotCommandOutputs (caseWhyNotProvider rolled in).
#[test]
#[serial]
-#[ignore = "panics in shirabe_php_shim::runtime::trigger_error (crates/shirabe-php-shim/src/runtime.rs:435 todo!()): emitting a PHP error obeys error_reporting and the installed error handler (runtime state not modeled), reached on the `why-not` command execution path"]
fn test_why_not_command_outputs() {
// caseWhyNotProvider: (package, version, expected_output, expected_status_code)
let cases: Vec<(&str, &str, &str, i32)> = vec![
diff --git a/crates/shirabe/tests/command/global_command_test.rs b/crates/shirabe/tests/command/global_command_test.rs
index 5f0efd0f..0446a007 100644
--- a/crates/shirabe/tests/command/global_command_test.rs
+++ b/crates/shirabe/tests/command/global_command_test.rs
@@ -31,7 +31,6 @@ fn chdir_unique_tmp_directory() -> TempDir {
#[test]
#[serial]
-#[ignore = "runs a composer.json script, which Application::do_run registers as a reflection-instantiated command; that registration path is todo!() at crates/shirabe/src/console/application.rs:2461 (plugin: register reflection-instantiated command on Application::add)"]
fn test_global() {
let _env_guard = EnvGuard;
diff --git a/crates/shirabe/tests/command/run_script_command_test.rs b/crates/shirabe/tests/command/run_script_command_test.rs
index 6c7f45c8..992fc6e2 100644
--- a/crates/shirabe/tests/command/run_script_command_test.rs
+++ b/crates/shirabe/tests/command/run_script_command_test.rs
@@ -124,7 +124,11 @@ fn test_can_define_aliases() {
/// ref: RunScriptCommandTest::testExecutionOfSimpleSymfonyCommand
#[test]
#[serial]
-#[ignore = "invoking the script name as a top-level composer command needs Application::do_run to import the user's PHP Command class as a live application command, which is a todo!() in application.rs, and the worker writes to inherited stdio the in-process application tester cannot capture"]
+#[ignore = "PhpCommandProxy::run hands the whole run to the worker-side console application, so the \
+ user's Command writes to the stdio the worker inherited and the in-process application \
+ tester's buffer stays empty. The worker is also a per-process singleton that keeps the \
+ working directory it was spawned in, so the relative psr-4 path this test's autoload \
+ config produces ('./MyCommand.php') only resolves when the test runs first in the binary"]
fn test_execution_of_simple_symfony_command() {
let description = "Sample description for test command";
let tear_down = init_temp_composer(
@@ -245,7 +249,11 @@ class MyCommand extends Command
/// ref: RunScriptCommandTest::testExecutionOfSymfonyCommandWithConfiguration
#[test]
#[serial]
-#[ignore = "invoking the script name as a top-level composer command needs Application::do_run to import the user's PHP Command class as a live application command, which is a todo!() in application.rs, and the worker writes to inherited stdio the in-process application tester cannot capture"]
+#[ignore = "PhpCommandProxy::run hands the whole run to the worker-side console application, so the \
+ user's Command writes to the stdio the worker inherited and the in-process application \
+ tester's buffer stays empty. The worker is also a per-process singleton that keeps the \
+ working directory it was spawned in, so the relative psr-4 path this test's autoload \
+ config produces ('./MyCommand.php') only resolves when the test runs first in the binary"]
fn test_execution_of_symfony_command_with_configuration() {
let cmd_name = "custom-cmd-123";
let cmd_alias = format!("{}-alias", cmd_name);
diff --git a/crates/shirabe/tests/package/loader/root_package_loader_test.rs b/crates/shirabe/tests/package/loader/root_package_loader_test.rs
index 51ca415f..3eb621b8 100644
--- a/crates/shirabe/tests/package/loader/root_package_loader_test.rs
+++ b/crates/shirabe/tests/package/loader/root_package_loader_test.rs
@@ -89,7 +89,6 @@ mockall::mock! {
}
#[test]
-#[ignore = "process_executor.enable_async() drives the async stream path, which calls stream_set_blocking (fcntl(2) todo!() in shirabe-php-shim::stream)"]
fn test_stability_flags_parsing() {
let io = null_io();
let config = std::rc::Rc::new(std::cell::RefCell::new(Config::new(true, None)));