Skip to content

Commit

Permalink
fix code
Browse files Browse the repository at this point in the history
  • Loading branch information
somtochiama committed May 14, 2024
1 parent 4fa6dab commit 1abc0e3
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions crates/corro-agent/src/agent/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ use std::{
};

use axum::Extension;
use futures::{stream::FuturesUnordered, StreamExt, TryStreamExt};
use futures::{future, stream::FuturesUnordered, StreamExt, TryStreamExt};
use hyper::StatusCode;
use rand::{
distributions::Uniform, prelude::Distribution, rngs::StdRng, seq::IteratorRandom, SeedableRng,
Expand Down Expand Up @@ -417,13 +417,12 @@ pub async fn configurable_stress_test(
}
})
.try_buffer_unordered(10)
.try_collect::<Vec<(ActorId, usize)>>().await?
.into_iter().fold(BTreeMap::new(), |mut acc, item| {
.try_fold(BTreeMap::new(), |mut acc, item| {
{
*acc.entry(item.0).or_insert(0) += item.1
}
acc
});
future::ready(Ok(acc))
}).await?;

let changes_count: i64 = 4 * input_count as i64;

Expand Down

0 comments on commit 1abc0e3

Please sign in to comment.