aboutsummaryrefslogtreecommitdiffhomepage
path: root/crates/shirabe/tests/downloader/fossil_downloader_test.rs
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2026-07-11 16:33:05 +0900
committernsfisis <nsfisis@gmail.com>2026-07-11 16:33:05 +0900
commit27d00055df8691a6bd99aaf38633a7338b16cc6a (patch)
tree4af17ccff5f8c2d09156fa62c559e60e3e683dac /crates/shirabe/tests/downloader/fossil_downloader_test.rs
parent1ec2220def43e37e5a65b96dde93c19b493258f4 (diff)
downloadphp-shirabe-27d00055df8691a6bd99aaf38633a7338b16cc6a.tar.gz
php-shirabe-27d00055df8691a6bd99aaf38633a7338b16cc6a.tar.zst
php-shirabe-27d00055df8691a6bd99aaf38633a7338b16cc6a.zip
chore: use fully-qualified name for Rc/RefCell
Diffstat (limited to 'crates/shirabe/tests/downloader/fossil_downloader_test.rs')
-rw-r--r--crates/shirabe/tests/downloader/fossil_downloader_test.rs21
1 files changed, 11 insertions, 10 deletions
diff --git a/crates/shirabe/tests/downloader/fossil_downloader_test.rs b/crates/shirabe/tests/downloader/fossil_downloader_test.rs
index 912b4b47..eed3d7fb 100644
--- a/crates/shirabe/tests/downloader/fossil_downloader_test.rs
+++ b/crates/shirabe/tests/downloader/fossil_downloader_test.rs
@@ -12,8 +12,6 @@ use shirabe::util::ProcessExecutor;
use shirabe::util::filesystem::{Filesystem, FilesystemMock};
use shirabe_php_shim::PhpMixed;
use shirabe_semver::VersionParser;
-use std::cell::RefCell;
-use std::rc::Rc;
use tempfile::TempDir;
fn run<F: std::future::Future>(future: F) -> F::Output {
@@ -67,20 +65,23 @@ fn get_package(source_reference: Option<&str>, source_url: Option<&str>) -> Pack
/// ref: FossilDownloaderTest::getDownloaderMock
fn get_downloader_mock(
- io: Option<Rc<RefCell<dyn IOInterface>>>,
+ io: Option<std::rc::Rc<std::cell::RefCell<dyn IOInterface>>>,
config: Option<Config>,
- process: Rc<RefCell<ProcessExecutor>>,
- filesystem: Option<Rc<RefCell<Filesystem>>>,
+ process: std::rc::Rc<std::cell::RefCell<ProcessExecutor>>,
+ filesystem: Option<std::rc::Rc<std::cell::RefCell<Filesystem>>>,
) -> FossilDownloader {
- let io =
- io.unwrap_or_else(|| Rc::new(RefCell::new(IOStub::new())) as Rc<RefCell<dyn IOInterface>>);
+ let io = io.unwrap_or_else(|| {
+ std::rc::Rc::new(std::cell::RefCell::new(IOStub::new()))
+ as std::rc::Rc<std::cell::RefCell<dyn IOInterface>>
+ });
// ref: getConfig(['secure-http' => false])
- let config = Rc::new(RefCell::new(config.unwrap_or_else(|| {
+ let config = std::rc::Rc::new(std::cell::RefCell::new(config.unwrap_or_else(|| {
ConfigStubBuilder::new()
.with("secure-http", PhpMixed::Bool(false))
.build()
})));
- let fs = filesystem.unwrap_or_else(|| Rc::new(RefCell::new(Filesystem::new(None))));
+ let fs = filesystem
+ .unwrap_or_else(|| std::rc::Rc::new(std::cell::RefCell::new(Filesystem::new(None))));
FossilDownloader::new(io, config, process, fs)
}
@@ -232,7 +233,7 @@ fn test_remove() {
remove_directory_async_result: Some(true),
..Default::default()
});
- let filesystem = Rc::new(RefCell::new(filesystem));
+ let filesystem = std::rc::Rc::new(std::cell::RefCell::new(filesystem));
let mut downloader = get_downloader_mock(None, None, process, Some(filesystem.clone()));
run(async {