Skip to content

Commit

Permalink
Update frontend
Browse files Browse the repository at this point in the history
  • Loading branch information
marlonbaeten committed Nov 14, 2023
1 parent 58ea113 commit e2cb6be
Show file tree
Hide file tree
Showing 5 changed files with 412 additions and 169 deletions.
17 changes: 10 additions & 7 deletions backend/src/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -172,15 +172,18 @@ async fn receive_message() {
#[ignore]
async fn measure_performance() {
let now = std::time::Instant::now();
let furures = (0..999).map(|_| {
send_message(false, true, false)
}).collect::<Vec<_>>();
let furures = (0..999)
.map(|_| send_message(false, true, false))
.collect::<Vec<_>>();

let mut i = 0;
futures::future::join_all(furures).await.iter().for_each(|e| {
i += 1;
println!("{i} {:?}", e.as_ref().unwrap().message().next());
});
futures::future::join_all(furures)
.await
.iter()
.for_each(|e| {
i += 1;
println!("{i} {:?}", e.as_ref().unwrap().message().next());
});

let later = std::time::Instant::now();
println!("Sending 1000 mails took {:?}", later - now);
Expand Down
Loading

0 comments on commit e2cb6be

Please sign in to comment.