Skip to content

Commit

Permalink
Ensure right record is updated in integration test (#1889)
Browse files Browse the repository at this point in the history
Update comment in test and add sleep to integration test to ensure the update of the right record
  • Loading branch information
morenol committed Nov 17, 2021
1 parent aa4e061 commit 0cd0a6e
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions crates/fluvio-spu/src/services/public/stream_fetch_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2261,6 +2261,9 @@ async fn test_stream_fetch_join(
.await
.expect("write");

// Sleep before sending records to left topic, so right record is updated
sleep(Duration::from_millis(100)).await;

// send back that consume has processed all current bacthes
client_socket
.send_and_receive(RequestMessage::new_request(UpdateOffsetsRequest {
Expand All @@ -2274,9 +2277,8 @@ async fn test_stream_fetch_join(

// Input: the following records:
//
// 33
// 44

// 55
// 66
let mut records_left = BatchProducer::builder()
.records(2u16)
.record_generator(Arc::new(|i, _| Record::new(((i + 5) * 11).to_string())))
Expand Down

0 comments on commit 0cd0a6e

Please sign in to comment.