Skip to content

Commit 18cf19b

Browse files
authored
fixes
1 parent 50d62f7 commit 18cf19b

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

crates/linking/src/lib.rs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -742,6 +742,18 @@ mod tests {
742742
});
743743
assert!(artifact_exists, "Expected UsesBoth artifact to be compiled");
744744

745+
// Seed empty expectations for all artifacts in this folder to avoid unexpected-ids.
746+
let mut linker = linker.output.artifact_ids().fold(linker, |acc, (id, _)| {
747+
let source = id
748+
.source
749+
.strip_prefix(acc.project.root())
750+
.unwrap_or(&id.source)
751+
.to_string_lossy()
752+
.into_owned();
753+
let identifier = format!("{source}:{}", id.name);
754+
acc.assert_dependencies(identifier, vec![])
755+
});
756+
745757
linker
746758
.assert_dependencies(
747759
"default/linking/samefile_union/SameFileUnion.t.sol:UsesBoth".to_string(),

0 commit comments

Comments
 (0)