Skip to content

Commit

Permalink
chore: Add comments in *_wrong_map tests
Browse files Browse the repository at this point in the history
  • Loading branch information
vadorovsky committed Jul 29, 2024
1 parent 25d986a commit e575712
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions aya/src/maps/bloom_filter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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::<u32>(BPF_MAP_TYPE_ARRAY));
let map = Map::Array(map);

Expand Down
2 changes: 2 additions & 0 deletions aya/src/maps/lpm_trie.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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::<u32>(BPF_MAP_TYPE_ARRAY));
let map = Map::Array(map);

Expand Down

0 comments on commit e575712

Please sign in to comment.