diff options
Diffstat (limited to 'crates')
39 files changed, 62 insertions, 48 deletions
diff --git a/crates/shirabe-external-packages/Cargo.toml b/crates/shirabe-external-packages/Cargo.toml index c1e70046..c9897725 100644 --- a/crates/shirabe-external-packages/Cargo.toml +++ b/crates/shirabe-external-packages/Cargo.toml @@ -7,6 +7,7 @@ edition.workspace = true shirabe-pcre.workspace = true shirabe-php-shim.workspace = true shirabe-semver.workspace = true +shirabe-symfony-process.workspace = true shirabe-symfony-string.workspace = true anyhow.workspace = true chrono.workspace = true diff --git a/crates/shirabe-external-packages/src/symfony.rs b/crates/shirabe-external-packages/src/symfony.rs index e0d9e4fe..23422146 100644 --- a/crates/shirabe-external-packages/src/symfony.rs +++ b/crates/shirabe-external-packages/src/symfony.rs @@ -1,4 +1,3 @@ pub mod console; pub mod filesystem; pub mod finder; -pub mod process; diff --git a/crates/shirabe-external-packages/src/symfony/console/command/dump_completion_command.rs b/crates/shirabe-external-packages/src/symfony/console/command/dump_completion_command.rs index 31a94f0f..cc46366c 100644 --- a/crates/shirabe-external-packages/src/symfony/console/command/dump_completion_command.rs +++ b/crates/shirabe-external-packages/src/symfony/console/command/dump_completion_command.rs @@ -9,8 +9,8 @@ use crate::symfony::console::input::input_argument::InputArgument; use crate::symfony::console::input::input_interface::InputInterface; use crate::symfony::console::input::input_option::InputOption; use crate::symfony::console::output::output_interface::{self, OutputInterface}; -use crate::symfony::process::process::Process; use shirabe_php_shim::{PhpMixed, impl_php_class}; +use shirabe_symfony_process::process::Process; use std::ops::{Deref, DerefMut}; /// __DIR__.'/../Resources/completion.bash', embedded at compile time (this port ships as a diff --git a/crates/shirabe-external-packages/src/symfony/console/helper/process_helper.rs b/crates/shirabe-external-packages/src/symfony/console/helper/process_helper.rs index 0f81348d..303a4569 100644 --- a/crates/shirabe-external-packages/src/symfony/console/helper/process_helper.rs +++ b/crates/shirabe-external-packages/src/symfony/console/helper/process_helper.rs @@ -6,8 +6,8 @@ use crate::symfony::console::helper::helper_interface::HelperInterface; use crate::symfony::console::helper::helper_set::HelperSet; use crate::symfony::console::output::ConsoleOutputInterface; use crate::symfony::console::output::output_interface::{self, OutputInterface}; -use crate::symfony::process::exception::process_failed_exception::ProcessFailedException; -use crate::symfony::process::process::Process; +use shirabe_symfony_process::exception::process_failed_exception::ProcessFailedException; +use shirabe_symfony_process::process::Process; /// The ProcessHelper class provides helpers to run external processes. /// diff --git a/crates/shirabe-php-rpc/Cargo.toml b/crates/shirabe-php-rpc/Cargo.toml index e4675faa..76775319 100644 --- a/crates/shirabe-php-rpc/Cargo.toml +++ b/crates/shirabe-php-rpc/Cargo.toml @@ -7,6 +7,7 @@ edition.workspace = true shirabe-external-packages.workspace = true shirabe-php-shim.workspace = true shirabe-php-src.workspace = true +shirabe-symfony-process.workspace = true anyhow.workspace = true indexmap.workspace = true nix.workspace = true diff --git a/crates/shirabe-php-rpc/src/lib.rs b/crates/shirabe-php-rpc/src/lib.rs index eac6f523..6dfdebf5 100644 --- a/crates/shirabe-php-rpc/src/lib.rs +++ b/crates/shirabe-php-rpc/src/lib.rs @@ -8,8 +8,8 @@ pub use value::{PhpClassHandle, PhpObjHandle, PhpObject, PluginValue, RustObjHan use frame::Frame; use indexmap::IndexMap; -use shirabe_external_packages::symfony::process::PhpExecutableFinder; use shirabe_php_shim::PhpMixed; +use shirabe_symfony_process::PhpExecutableFinder; use std::os::unix::net::UnixStream; use std::sync::atomic::{AtomicBool, AtomicU64, Ordering}; use std::sync::{LazyLock, Mutex, OnceLock}; diff --git a/crates/shirabe-php-rpc/tests/generated_stubs.rs b/crates/shirabe-php-rpc/tests/generated_stubs.rs index b4ff8197..0980745e 100644 --- a/crates/shirabe-php-rpc/tests/generated_stubs.rs +++ b/crates/shirabe-php-rpc/tests/generated_stubs.rs @@ -6,7 +6,7 @@ //! report; when any of those is missing the test returns early, following the non-mock test //! convention of this crate. -use shirabe_external_packages::symfony::process::PhpExecutableFinder; +use shirabe_symfony_process::PhpExecutableFinder; use std::path::Path; #[test] diff --git a/crates/shirabe-php-rpc/tests/oracle.rs b/crates/shirabe-php-rpc/tests/oracle.rs index e1e1143b..b98f2203 100644 --- a/crates/shirabe-php-rpc/tests/oracle.rs +++ b/crates/shirabe-php-rpc/tests/oracle.rs @@ -7,9 +7,9 @@ //! focus areas. use indexmap::IndexMap; -use shirabe_external_packages::symfony::process::PhpExecutableFinder; use shirabe_php_rpc::value::{serialize, unserialize}; use shirabe_php_rpc::{PhpObject, PluginValue, call_function}; +use shirabe_symfony_process::PhpExecutableFinder; fn php_available() -> bool { PhpExecutableFinder::new().find(false).is_some() diff --git a/crates/shirabe-symfony-process/Cargo.toml b/crates/shirabe-symfony-process/Cargo.toml new file mode 100644 index 00000000..e0dfa684 --- /dev/null +++ b/crates/shirabe-symfony-process/Cargo.toml @@ -0,0 +1,12 @@ +[package] +name = "shirabe-symfony-process" +version.workspace = true +edition.workspace = true + +[dependencies] +shirabe-php-shim.workspace = true +anyhow.workspace = true +indexmap.workspace = true + +[lints] +workspace = true diff --git a/crates/shirabe-external-packages/src/symfony/process/exception.rs b/crates/shirabe-symfony-process/src/exception.rs index 689a64b6..689a64b6 100644 --- a/crates/shirabe-external-packages/src/symfony/process/exception.rs +++ b/crates/shirabe-symfony-process/src/exception.rs diff --git a/crates/shirabe-external-packages/src/symfony/process/exception/invalid_argument_exception.rs b/crates/shirabe-symfony-process/src/exception/invalid_argument_exception.rs index c9a42653..c9a42653 100644 --- a/crates/shirabe-external-packages/src/symfony/process/exception/invalid_argument_exception.rs +++ b/crates/shirabe-symfony-process/src/exception/invalid_argument_exception.rs diff --git a/crates/shirabe-external-packages/src/symfony/process/exception/logic_exception.rs b/crates/shirabe-symfony-process/src/exception/logic_exception.rs index 36e9bcca..36e9bcca 100644 --- a/crates/shirabe-external-packages/src/symfony/process/exception/logic_exception.rs +++ b/crates/shirabe-symfony-process/src/exception/logic_exception.rs diff --git a/crates/shirabe-external-packages/src/symfony/process/exception/process_failed_exception.rs b/crates/shirabe-symfony-process/src/exception/process_failed_exception.rs index e5d6d7fc..76520b33 100644 --- a/crates/shirabe-external-packages/src/symfony/process/exception/process_failed_exception.rs +++ b/crates/shirabe-symfony-process/src/exception/process_failed_exception.rs @@ -1,8 +1,8 @@ //! ref: composer/vendor/symfony/process/Exception/ProcessFailedException.php -use crate::symfony::process::exception::invalid_argument_exception::InvalidArgumentException; -use crate::symfony::process::exception::runtime_exception::RuntimeException; -use crate::symfony::process::process::Process; +use crate::exception::invalid_argument_exception::InvalidArgumentException; +use crate::exception::runtime_exception::RuntimeException; +use crate::process::Process; #[derive(Debug)] pub struct ProcessFailedException { diff --git a/crates/shirabe-external-packages/src/symfony/process/exception/process_signaled_exception.rs b/crates/shirabe-symfony-process/src/exception/process_signaled_exception.rs index 9f325750..e570c80d 100644 --- a/crates/shirabe-external-packages/src/symfony/process/exception/process_signaled_exception.rs +++ b/crates/shirabe-symfony-process/src/exception/process_signaled_exception.rs @@ -1,7 +1,7 @@ //! ref: composer/vendor/symfony/process/Exception/ProcessSignaledException.php -use crate::symfony::process::exception::runtime_exception::RuntimeException; -use crate::symfony::process::process::Process; +use crate::exception::runtime_exception::RuntimeException; +use crate::process::Process; #[derive(Debug)] pub struct ProcessSignaledException { diff --git a/crates/shirabe-external-packages/src/symfony/process/exception/process_timed_out_exception.rs b/crates/shirabe-symfony-process/src/exception/process_timed_out_exception.rs index 9485d1c2..b7e6595d 100644 --- a/crates/shirabe-external-packages/src/symfony/process/exception/process_timed_out_exception.rs +++ b/crates/shirabe-symfony-process/src/exception/process_timed_out_exception.rs @@ -1,7 +1,7 @@ //! ref: composer/vendor/symfony/process/Exception/ProcessTimedOutException.php -use crate::symfony::process::exception::runtime_exception::RuntimeException; -use crate::symfony::process::process::Process; +use crate::exception::runtime_exception::RuntimeException; +use crate::process::Process; #[derive(Debug)] pub struct ProcessTimedOutException { diff --git a/crates/shirabe-external-packages/src/symfony/process/exception/runtime_exception.rs b/crates/shirabe-symfony-process/src/exception/runtime_exception.rs index e9cc31e0..e9cc31e0 100644 --- a/crates/shirabe-external-packages/src/symfony/process/exception/runtime_exception.rs +++ b/crates/shirabe-symfony-process/src/exception/runtime_exception.rs diff --git a/crates/shirabe-external-packages/src/symfony/process/executable_finder.rs b/crates/shirabe-symfony-process/src/executable_finder.rs index 5b1c0994..5b1c0994 100644 --- a/crates/shirabe-external-packages/src/symfony/process/executable_finder.rs +++ b/crates/shirabe-symfony-process/src/executable_finder.rs diff --git a/crates/shirabe-external-packages/src/symfony/process.rs b/crates/shirabe-symfony-process/src/lib.rs index 3a5656c6..3a5656c6 100644 --- a/crates/shirabe-external-packages/src/symfony/process.rs +++ b/crates/shirabe-symfony-process/src/lib.rs diff --git a/crates/shirabe-external-packages/src/symfony/process/php_executable_finder.rs b/crates/shirabe-symfony-process/src/php_executable_finder.rs index e8661866..e8661866 100644 --- a/crates/shirabe-external-packages/src/symfony/process/php_executable_finder.rs +++ b/crates/shirabe-symfony-process/src/php_executable_finder.rs diff --git a/crates/shirabe-external-packages/src/symfony/process/pipes.rs b/crates/shirabe-symfony-process/src/pipes.rs index 6c3ea7dd..6c3ea7dd 100644 --- a/crates/shirabe-external-packages/src/symfony/process/pipes.rs +++ b/crates/shirabe-symfony-process/src/pipes.rs diff --git a/crates/shirabe-external-packages/src/symfony/process/pipes/abstract_pipes.rs b/crates/shirabe-symfony-process/src/pipes/abstract_pipes.rs index 8741926c..8741926c 100644 --- a/crates/shirabe-external-packages/src/symfony/process/pipes/abstract_pipes.rs +++ b/crates/shirabe-symfony-process/src/pipes/abstract_pipes.rs diff --git a/crates/shirabe-external-packages/src/symfony/process/pipes/pipes_interface.rs b/crates/shirabe-symfony-process/src/pipes/pipes_interface.rs index 46609bb8..46609bb8 100644 --- a/crates/shirabe-external-packages/src/symfony/process/pipes/pipes_interface.rs +++ b/crates/shirabe-symfony-process/src/pipes/pipes_interface.rs diff --git a/crates/shirabe-external-packages/src/symfony/process/pipes/unix_pipes.rs b/crates/shirabe-symfony-process/src/pipes/unix_pipes.rs index a7026318..bfc93d44 100644 --- a/crates/shirabe-external-packages/src/symfony/process/pipes/unix_pipes.rs +++ b/crates/shirabe-symfony-process/src/pipes/unix_pipes.rs @@ -1,8 +1,8 @@ //! ref: composer/vendor/symfony/process/Pipes/UnixPipes.php -use crate::symfony::process::pipes::abstract_pipes::AbstractPipes; -use crate::symfony::process::pipes::pipes_interface::{CHUNK_SIZE, PipesInterface}; -use crate::symfony::process::process::Process; +use crate::pipes::abstract_pipes::AbstractPipes; +use crate::pipes::pipes_interface::{CHUNK_SIZE, PipesInterface}; +use crate::process::Process; use indexmap::IndexMap; use shirabe_php_shim::{Descriptor, PhpMixed, PhpResource}; diff --git a/crates/shirabe-external-packages/src/symfony/process/pipes/windows_pipes.rs b/crates/shirabe-symfony-process/src/pipes/windows_pipes.rs index cf4f3414..87bf5126 100644 --- a/crates/shirabe-external-packages/src/symfony/process/pipes/windows_pipes.rs +++ b/crates/shirabe-symfony-process/src/pipes/windows_pipes.rs @@ -1,7 +1,7 @@ //! ref: composer/vendor/symfony/process/Pipes/WindowsPipes.php -use crate::symfony::process::pipes::abstract_pipes::AbstractPipes; -use crate::symfony::process::pipes::pipes_interface::PipesInterface; +use crate::pipes::abstract_pipes::AbstractPipes; +use crate::pipes::pipes_interface::PipesInterface; use indexmap::IndexMap; use shirabe_php_shim::{Descriptor, PhpMixed, PhpResource}; diff --git a/crates/shirabe-external-packages/src/symfony/process/process.rs b/crates/shirabe-symfony-process/src/process.rs index 3fb3fab2..6a078b9e 100644 --- a/crates/shirabe-external-packages/src/symfony/process/process.rs +++ b/crates/shirabe-symfony-process/src/process.rs @@ -1,15 +1,15 @@ //! ref: composer/vendor/symfony/process/Process.php -use crate::symfony::process::exception::invalid_argument_exception::InvalidArgumentException; -use crate::symfony::process::exception::logic_exception::LogicException; -use crate::symfony::process::exception::process_signaled_exception::ProcessSignaledException; -use crate::symfony::process::exception::process_timed_out_exception::ProcessTimedOutException; -use crate::symfony::process::exception::runtime_exception::RuntimeException; -use crate::symfony::process::executable_finder::ExecutableFinder; -use crate::symfony::process::pipes::pipes_interface::PipesInterface; -use crate::symfony::process::pipes::unix_pipes::UnixPipes; -use crate::symfony::process::pipes::windows_pipes::WindowsPipes; -use crate::symfony::process::process_utils::ProcessUtils; +use crate::exception::invalid_argument_exception::InvalidArgumentException; +use crate::exception::logic_exception::LogicException; +use crate::exception::process_signaled_exception::ProcessSignaledException; +use crate::exception::process_timed_out_exception::ProcessTimedOutException; +use crate::exception::runtime_exception::RuntimeException; +use crate::executable_finder::ExecutableFinder; +use crate::pipes::pipes_interface::PipesInterface; +use crate::pipes::unix_pipes::UnixPipes; +use crate::pipes::windows_pipes::WindowsPipes; +use crate::process_utils::ProcessUtils; use indexmap::IndexMap; use shirabe_php_shim::{Descriptor, PhpMixed, PhpResource, php_regex}; use std::sync::OnceLock; diff --git a/crates/shirabe-external-packages/src/symfony/process/process_utils.rs b/crates/shirabe-symfony-process/src/process_utils.rs index 71943b80..7c4ca21f 100644 --- a/crates/shirabe-external-packages/src/symfony/process/process_utils.rs +++ b/crates/shirabe-symfony-process/src/process_utils.rs @@ -1,6 +1,6 @@ //! ref: composer/vendor/symfony/process/ProcessUtils.php -use crate::symfony::process::exception::invalid_argument_exception::InvalidArgumentException; +use crate::exception::invalid_argument_exception::InvalidArgumentException; use shirabe_php_shim::PhpMixed; /// ProcessUtils is a bunch of utility methods. diff --git a/crates/shirabe/Cargo.toml b/crates/shirabe/Cargo.toml index 3ac40475..64aa14e0 100644 --- a/crates/shirabe/Cargo.toml +++ b/crates/shirabe/Cargo.toml @@ -12,6 +12,7 @@ shirabe-php-rpc.workspace = true shirabe-php-shim.workspace = true shirabe-semver.workspace = true shirabe-spdx-licenses.workspace = true +shirabe-symfony-process.workspace = true anyhow.workspace = true async-trait.workspace = true base64.workspace = true diff --git a/crates/shirabe/src/command/diagnose_command.rs b/crates/shirabe/src/command/diagnose_command.rs index 9f834315..b6b1ffad 100644 --- a/crates/shirabe/src/command/diagnose_command.rs +++ b/crates/shirabe/src/command/diagnose_command.rs @@ -36,7 +36,6 @@ use indexmap::IndexMap; use shirabe_external_packages::symfony::console::command::command::Command; use shirabe_external_packages::symfony::console::input::InputInterface; use shirabe_external_packages::symfony::console::output::OutputInterface; -use shirabe_external_packages::symfony::process::ExecutableFinder; use shirabe_pcre::{CaptureKey, Preg}; use shirabe_php_shim::Catch as _; use shirabe_php_shim::{ @@ -45,6 +44,7 @@ use shirabe_php_shim::{ is_string, php_regex, rtrim, str_contains, str_replace, str_starts_with, strpos, strstr, strstr3, strtolower, trim, version_compare, }; +use shirabe_symfony_process::ExecutableFinder; #[derive(Debug)] pub struct DiagnoseCommand { diff --git a/crates/shirabe/src/console/application.rs b/crates/shirabe/src/console/application.rs index 05cd1d22..8b60c988 100644 --- a/crates/shirabe/src/console/application.rs +++ b/crates/shirabe/src/console/application.rs @@ -92,7 +92,6 @@ use shirabe_external_packages::symfony::console::signal_registry::signal_registr use shirabe_external_packages::symfony::console::style::style_interface::StyleInterface; use shirabe_external_packages::symfony::console::style::symfony_style::SymfonyStyle; use shirabe_external_packages::symfony::console::terminal::Terminal; -use shirabe_external_packages::symfony::process::exception::ProcessTimedOutException; use shirabe_php_shim::Catch as _; use shirabe_php_shim::{ LogicException as ShimLogicException, PHP_VERSION, PHP_VERSION_ID, PhpMixed, RuntimeException, @@ -103,6 +102,7 @@ use shirabe_php_shim::{ php_uname, posix_getuid, random_bytes, realpath, restore_error_handler, round, str_contains, str_replace, strpos, strtoupper, sys_get_temp_dir, time, unlink, }; +use shirabe_symfony_process::exception::ProcessTimedOutException; /// The PHP `Composer\Console\Application` and `Symfony\Component\Console\Application` are /// flattened into a single struct. Methods that are overridden by subclass and called via diff --git a/crates/shirabe/src/downloader/zip_downloader.rs b/crates/shirabe/src/downloader/zip_downloader.rs index fd7d66d3..ddbb6788 100644 --- a/crates/shirabe/src/downloader/zip_downloader.rs +++ b/crates/shirabe/src/downloader/zip_downloader.rs @@ -8,7 +8,6 @@ use crate::package::PackageInterfaceHandle; use crate::util::IniHelper; use crate::util::Platform; use indexmap::IndexMap; -use shirabe_external_packages::symfony::process::ExecutableFinder; use shirabe_pcre::{CaptureKey, Preg}; use shirabe_php_shim::Catch as _; use shirabe_php_shim::{ @@ -17,6 +16,7 @@ use shirabe_php_shim::{ impl_php_class, is_file, json_encode, php_regex, random_int, str_contains, str_replace, strlen, substr, version_compare, }; +use shirabe_symfony_process::ExecutableFinder; use std::sync::Mutex; static UNZIP_COMMANDS: Mutex<Option<Vec<Vec<String>>>> = Mutex::new(None); diff --git a/crates/shirabe/src/event_dispatcher/event_dispatcher.rs b/crates/shirabe/src/event_dispatcher/event_dispatcher.rs index 4386204f..04c590c6 100644 --- a/crates/shirabe/src/event_dispatcher/event_dispatcher.rs +++ b/crates/shirabe/src/event_dispatcher/event_dispatcher.rs @@ -22,8 +22,6 @@ use crate::util::Platform; use crate::util::ProcessExecutor; use indexmap::IndexMap; use shirabe_external_packages::symfony::console::output::output_interface; -use shirabe_external_packages::symfony::process::ExecutableFinder; -use shirabe_external_packages::symfony::process::PhpExecutableFinder; use shirabe_pcre::{CaptureKey, Preg}; use shirabe_php_rpc::{ PhpThrow, PluginValue, RustMethodDispatcher, RustObjHandle, call_function, @@ -38,6 +36,8 @@ use shirabe_php_shim::{ str_contains, str_ends_with, str_replace, str_starts_with, strlen, strpos, strtoupper, substr, trim, }; +use shirabe_symfony_process::ExecutableFinder; +use shirabe_symfony_process::PhpExecutableFinder; /// Represents a callable listener. PHP's `callable` may be a string (command, script, or /// "Class::method"), a `[object|string, method]` pair, or a `\Closure`. diff --git a/crates/shirabe/src/platform/hhvm_detector.rs b/crates/shirabe/src/platform/hhvm_detector.rs index 69871f1f..26fb5e12 100644 --- a/crates/shirabe/src/platform/hhvm_detector.rs +++ b/crates/shirabe/src/platform/hhvm_detector.rs @@ -2,8 +2,8 @@ use crate::util::Platform; use crate::util::ProcessExecutor; -use shirabe_external_packages::symfony::process::ExecutableFinder; use shirabe_php_shim::{HHVM_VERSION, defined}; +use shirabe_symfony_process::ExecutableFinder; use std::sync::Mutex; // None = null (uninitialized), Some(None) = false (not found), Some(Some(v)) = version diff --git a/crates/shirabe/src/util/perforce.rs b/crates/shirabe/src/util/perforce.rs index f03e4835..1820936c 100644 --- a/crates/shirabe/src/util/perforce.rs +++ b/crates/shirabe/src/util/perforce.rs @@ -6,14 +6,14 @@ use crate::util::Filesystem; use crate::util::Platform; use crate::util::ProcessExecutor; use indexmap::IndexMap; -use shirabe_external_packages::symfony::process::ExecutableFinder; -use shirabe_external_packages::symfony::process::Process; use shirabe_pcre::Preg; use shirabe_php_shim::{ Exception, PHP_EOL, PhpMixed, PhpResource, chdir, date, explode, fclose, feof, fgets, file_get_contents, fopen, fwrite, gethostname, json_decode, php_regex, str_replace_array, strcmp, strlen, strpos, strrpos, substr, time, trim, }; +use shirabe_symfony_process::ExecutableFinder; +use shirabe_symfony_process::Process; /// @phpstan-type RepoConfig array{unique_perforce_client_name?: string, depot?: string, branch?: string, p4user?: string, p4password?: string} #[derive(Debug)] diff --git a/crates/shirabe/src/util/process_executor.rs b/crates/shirabe/src/util/process_executor.rs index 2b4c0d89..56199868 100644 --- a/crates/shirabe/src/util/process_executor.rs +++ b/crates/shirabe/src/util/process_executor.rs @@ -7,11 +7,6 @@ use crate::util::GitHub; use crate::util::Platform; use indexmap::IndexMap; use shirabe_external_packages::seld::signal::SignalHandler; -use shirabe_external_packages::symfony::process::ExecutableFinder; -use shirabe_external_packages::symfony::process::Process; -use shirabe_external_packages::symfony::process::ProcessMock; -use shirabe_external_packages::symfony::process::exception::ProcessSignaledException; -use shirabe_external_packages::symfony::process::exception::RuntimeException as SymfonyProcessRuntimeException; use shirabe_pcre::{CaptureKey, Preg}; use shirabe_php_shim::Catch as _; use shirabe_php_shim::{ @@ -20,6 +15,11 @@ use shirabe_php_shim::{ php_regex, rtrim, str_replace, strcspn, strlen, strpbrk, strtolower, strtr_array, substr_replace, trim, }; +use shirabe_symfony_process::ExecutableFinder; +use shirabe_symfony_process::Process; +use shirabe_symfony_process::ProcessMock; +use shirabe_symfony_process::exception::ProcessSignaledException; +use shirabe_symfony_process::exception::RuntimeException as SymfonyProcessRuntimeException; use std::sync::{LazyLock, Mutex}; static EXECUTABLES: LazyLock<Mutex<IndexMap<String, String>>> = diff --git a/crates/shirabe/tests/command/self_update_command_test.rs b/crates/shirabe/tests/command/self_update_command_test.rs index 6dc64104..1f83af66 100644 --- a/crates/shirabe/tests/command/self_update_command_test.rs +++ b/crates/shirabe/tests/command/self_update_command_test.rs @@ -3,8 +3,8 @@ use crate::test_case::{RunOptions, get_application_tester, init_temp_composer}; use indexmap::IndexMap; use serial_test::serial; -use shirabe_external_packages::symfony::process::Process; use shirabe_php_shim::{PHP_BINARY, PhpMixed}; +use shirabe_symfony_process::Process; /// ref: SelfUpdateCommandTest::setUp. The `composer-test.phar` copy PHP also performs here lives in /// `set_up_with_phar` instead, so the one test that never touches the phar is not blocked by the diff --git a/crates/shirabe/tests/package/archiver/archivable_files_finder_test.rs b/crates/shirabe/tests/package/archiver/archivable_files_finder_test.rs index 2e5aa738..499e08dc 100644 --- a/crates/shirabe/tests/package/archiver/archivable_files_finder_test.rs +++ b/crates/shirabe/tests/package/archiver/archivable_files_finder_test.rs @@ -3,9 +3,9 @@ use indexmap::IndexMap; use shirabe::package::archiver::ArchivableFilesFinder; use shirabe::util::Filesystem; -use shirabe_external_packages::symfony::process::Process; use shirabe_pcre::Preg; use shirabe_php_shim::{PhpMixed, ZipArchive, dirname, file_put_contents, preg_quote}; +use shirabe_symfony_process::Process; use tempfile::TempDir; struct SetUp { diff --git a/crates/shirabe/tests/package/archiver/archive_manager_test.rs b/crates/shirabe/tests/package/archiver/archive_manager_test.rs index 84feb5bc..43e2f84a 100644 --- a/crates/shirabe/tests/package/archiver/archive_manager_test.rs +++ b/crates/shirabe/tests/package/archiver/archive_manager_test.rs @@ -12,11 +12,11 @@ use shirabe::util::Filesystem; use shirabe::util::ProcessExecutor; use shirabe::util::http_downloader::HttpDownloader; use shirabe::util::r#loop::Loop; -use shirabe_external_packages::symfony::process::Process; use shirabe_php_shim::Catch as _; use shirabe_php_shim::{ PhpMixed, file_exists, file_put_contents, realpath, sys_get_temp_dir, unlink, }; +use shirabe_symfony_process::Process; use tempfile::TempDir; // ref: ArchiverTestCase::setUp + ArchiveManagerTest::setUp. diff --git a/crates/shirabe/tests/platform/hhvm_detector_test.rs b/crates/shirabe/tests/platform/hhvm_detector_test.rs index 340bf888..ea75ec8b 100644 --- a/crates/shirabe/tests/platform/hhvm_detector_test.rs +++ b/crates/shirabe/tests/platform/hhvm_detector_test.rs @@ -4,9 +4,9 @@ use shirabe::platform::hhvm_detector::HhvmDetector; use shirabe::platform::hhvm_detector::HhvmDetectorInterface; use shirabe::util::Platform; use shirabe::util::ProcessExecutor; -use shirabe_external_packages::symfony::process::ExecutableFinder; use shirabe_php_shim::PhpMixed; use shirabe_semver::VersionParser; +use shirabe_symfony_process::ExecutableFinder; fn set_up() -> HhvmDetector { let hhvm_detector = HhvmDetector::new(None, None); diff --git a/crates/shirabe/tests/plugin/plugin_installer_test.rs b/crates/shirabe/tests/plugin/plugin_installer_test.rs index 0c82a11a..65a8872b 100644 --- a/crates/shirabe/tests/plugin/plugin_installer_test.rs +++ b/crates/shirabe/tests/plugin/plugin_installer_test.rs @@ -30,10 +30,10 @@ use shirabe::util::http_downloader::HttpDownloader; use shirabe::util::r#loop::Loop; use shirabe::util::process_executor::ProcessExecutor; use shirabe_external_packages::symfony::console::output::output_interface::VERBOSITY_NORMAL; -use shirabe_external_packages::symfony::process::PhpExecutableFinder; use shirabe_php_shim::Catch as _; use shirabe_php_shim::PhpMixed; use shirabe_semver::VersionParser; +use shirabe_symfony_process::PhpExecutableFinder; use tempfile::TempDir; /// The register/activate flow runs the plugin in the real PHP worker; without a PHP binary the |
