fix(solc): off by one error finding version intersection (#930)
* fix: off by one error while finding intersection * test: enable test
This commit is contained in:
parent
d8e5e536cc
commit
28df48b530
|
@ -79,7 +79,8 @@ pub static RELEASES: once_cell::sync::Lazy<(svm::Releases, Vec<Version>, bool)>
|
|||
|
||||
/// A `Solc` version is either installed (available locally) or can be downloaded, from the remote
|
||||
/// endpoint
|
||||
#[derive(Debug, Clone, Eq, PartialEq, Ord, PartialOrd, Hash)]
|
||||
#[derive(Debug, Clone, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
|
||||
#[serde(untagged)]
|
||||
pub enum SolcVersion {
|
||||
Installed(Version),
|
||||
Remote(Version),
|
||||
|
|
|
@ -476,7 +476,7 @@ impl Graph {
|
|||
}
|
||||
|
||||
let mut result = sets.pop().cloned().expect("not empty; qed.").clone();
|
||||
if sets.len() > 1 {
|
||||
if !sets.is_empty() {
|
||||
result.retain(|item| sets.iter().all(|set| set.contains(item)));
|
||||
}
|
||||
|
||||
|
|
|
@ -24,7 +24,6 @@ fn init_tracing() {
|
|||
}
|
||||
|
||||
#[test]
|
||||
#[ignore]
|
||||
fn can_get_versioned_linkrefs() {
|
||||
let root = PathBuf::from(env!("CARGO_MANIFEST_DIR")).join("test-data/test-versioned-linkrefs");
|
||||
let paths = ProjectPathsConfig::builder()
|
||||
|
@ -37,8 +36,6 @@ fn can_get_versioned_linkrefs() {
|
|||
|
||||
let compiled = project.compile().unwrap();
|
||||
assert!(!compiled.has_compiler_errors());
|
||||
|
||||
// TODO:
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
|
Loading…
Reference in New Issue