Skip to content

Commit

Permalink
Fix async tests
Browse files Browse the repository at this point in the history
  • Loading branch information
JHawk0224 committed Dec 12, 2023
1 parent 33ead91 commit 773c204
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ async fn test_producer() {

// How a client would make a producer

let mut producer = Producer::new(lead_addr).await;
let mut producer = Producer::new(lead_addr);
producer.add_topic("Best foods".to_string()).await.unwrap();
producer
.send_message("Best foods".to_string(), "pizza is a good food".to_string())
Expand All @@ -180,7 +180,7 @@ async fn test_multiple_topics() {
let _ = run_kafka(lead_addr, 8001);

// How a client would make a producer
let mut producer = Producer::new(lead_addr).await;
let mut producer = Producer::new(lead_addr);
producer.add_topic("Best foods".to_string()).await.unwrap();
producer.add_topic("Best drinks".to_string()).await.unwrap();
producer
Expand Down Expand Up @@ -216,7 +216,7 @@ async fn test_producer_consumer() {
let _ = run_kafka(lead_addr, 8001);

// How a client would make a producer
let mut producer = Producer::new(lead_addr).await;
let mut producer = Producer::new(lead_addr);
producer.add_topic("Best foods".to_string()).await.unwrap();

let mut consumer = consumer::Consumer::new(8080, lead_addr);
Expand Down

0 comments on commit 773c204

Please sign in to comment.