diff --git a/aya/src/maps/bloom_filter.rs b/aya/src/maps/bloom_filter.rs index daeaa46c..bc060d87 100644 --- a/aya/src/maps/bloom_filter.rs +++ b/aya/src/maps/bloom_filter.rs @@ -120,6 +120,8 @@ mod tests { #[test] fn test_try_from_wrong_map() { + // This is necessary to stop miri tripping over the PERF_EVENT_ARRAY + // logic and attempting to open a file to read number of online CPUs. let map = new_map(test_utils::new_obj_map::(BPF_MAP_TYPE_ARRAY)); let map = Map::Array(map); diff --git a/aya/src/maps/lpm_trie.rs b/aya/src/maps/lpm_trie.rs index 37377efa..29ab5c29 100644 --- a/aya/src/maps/lpm_trie.rs +++ b/aya/src/maps/lpm_trie.rs @@ -249,6 +249,8 @@ mod tests { #[test] fn test_try_from_wrong_map() { + // This is necessary to stop miri tripping over the PERF_EVENT_ARRAY + // logic and attempting to open a file to read number of online CPUs. let map = new_map(test_utils::new_obj_map::(BPF_MAP_TYPE_ARRAY)); let map = Map::Array(map);