Fix tests

This commit is contained in:
Omar Abdulla
2025-09-04 14:40:09 +03:00
parent b4118faa3d
commit a30d4f9b9e
2 changed files with 4 additions and 3 deletions
+3 -2
View File
@@ -46,7 +46,8 @@ impl SolidityCompiler for Solc {
// This is a cache for the compiler objects so that whenever the same compiler version is // This is a cache for the compiler objects so that whenever the same compiler version is
// requested the same object is returned. We do this as we do not want to keep cloning the // requested the same object is returned. We do this as we do not want to keep cloning the
// compiler around. // compiler around.
static COMPILERS_CACHE: LazyLock<DashMap<Version, Solc>> = LazyLock::new(Default::default); static COMPILERS_CACHE: LazyLock<DashMap<(PathBuf, Version), Solc>> =
LazyLock::new(Default::default);
let working_directory_configuration = let working_directory_configuration =
AsRef::<WorkingDirectoryConfiguration>::as_ref(&context); AsRef::<WorkingDirectoryConfiguration>::as_ref(&context);
@@ -65,7 +66,7 @@ impl SolidityCompiler for Solc {
.context("Failed to download/get path to solc binary")?; .context("Failed to download/get path to solc binary")?;
Ok(COMPILERS_CACHE Ok(COMPILERS_CACHE
.entry(version.clone()) .entry((path.clone(), version.clone()))
.or_insert_with(|| { .or_insert_with(|| {
Self(Arc::new(SolcInner { Self(Arc::new(SolcInner {
solc_path: path, solc_path: path,
+1 -1
View File
@@ -256,7 +256,7 @@ pub struct KitchensinkConfiguration {
#[clap( #[clap(
id = "kitchensink.path", id = "kitchensink.path",
long = "kitchensink.path", long = "kitchensink.path",
default_value = "kitchensink" default_value = "substrate-node"
)] )]
pub path: PathBuf, pub path: PathBuf,