Commit 90f48249 authored by Acrimon's avatar Acrimon

[DashMap] added test for iter_mut.

parent a1ac4181
Pipeline #411 passed with stages
in 5 minutes and 41 seconds
......@@ -918,6 +918,19 @@ mod tests {
assert_eq!(map.iter().count(), 1024);
}
#[test]
fn insert_then_iter_mut_map_1024() {
let map = DashMap::default();
for i in 0..1024_i32 {
map.insert(i, 4);
}
map.iter_mut().for_each(|mut r| *r *= 2);
assert_eq!(map.iter().fold(0, |acc, e| acc + *e), 8192);
}
#[test]
fn insert_then_assert_str() {
let map = DashMap::default();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment