You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: basic.rs
    path of file: ./repos/nearcore/chain/chunks/src/test
    
    the code of the file until where you have to start completion: use std::collections::HashSet;

use derive_enum_from_into::{EnumFrom, EnumTryInto};
use near_async::messaging::noop;
use near_async::time;
use near_async::{
    messaging::{CanSend, IntoSender},
    test_loop::{
        adhoc::{handle_adhoc_events, AdhocEvent, AdhocEventSender},
        event_handler::capture_events,
    },
};
use near_chain::chunks_store::ReadOnlyChunksStore;
use near_epoch_manager::test_utils::hash_range;
use near_network::{
    shards_manager::ShardsManagerRequestFromNetwork,
    types::{NetworkRequests, PeerManagerMessageRequest},
};
use near_primitives::types::{AccountId, BlockHeight};
use near_store::test_utils::create_test_store;
use tracing::log::info;

use crate::{
    adapter::ShardsManagerRequestFromClient,
    client::ShardsManagerResponse,
    test_loop::{
        forward_client_request_to_shards_manager, forward_network_request_to_shards_manager,
        periodically_resend_chunk_requests, MockChainForShardsManager,
        MockChainForShardsManagerConfig, ShardsManagerResendChunkRequests
    
fn test_basic_receive_complete_chunk() {
    let builder = ShardsManagerTestLoopBuilder::new();
    let validators = (0..5)
        .map(|i| format!("validator_{}", i).parse::<AccountId>().unwrap())
        .collect::<Vec<_>>();

    let store = create_test_store();
    let chain = MockChainForShardsManager::new(
        store.clone(),
        MockChainForShardsManagerConfig {
            account_id: validators[0].clone(),
            block_producers: validators.clone(),
            chunk_only_producers: vec![],
            epoch_length: 2,
            num_shards: 3,
            track_all_shards: true,
            shards_manager: builder.sender().into_sender(),
        },
    );

    let shards_manager = ShardsManager::new(
        builder.clock(),
        Some(validators[0].clone()),
        chain.epoch_manager.clone(),
        chain.shard_tracker.clone(),
        noop().into_sender(),
        builder.sender().into_sender(),
        ReadOnlyChunksStore::new(store),
        default_tip(),
        default_tip(),
    );
    let test_data = TestData::new(shards_manager, chain);
    let mut test = builder.build(test_data);
    test.register_handler(forward_client_request_to_shards_manager().widen());
    test.register_handler(forward_network_request_to_shards_manager().widen());
    test.register_handler(capture_events::<ShardsManagerResponse>().widen());

    // Have the ShardsManager receive a PartialEncodedChunk with all parts.
    let chunk = test.data.chain.produce_chunk_signed_by_chunk_producer(2);
    test.sender().send(TestEvent::NetworkToShardsManager(
        ShardsManagerRequestFromNetwork::ProcessPartialEncodedChunk(
            chunk.make_partial_encoded_chunk(&chunk.part_ords(), &[]),
        ),
    ));
    test.run_for(time::Duration::seconds(1));

    assert_eq!(test.data.client_events.len(), 2);
    match &test.data.client_events[0] {
        ShardsManagerResponse::ChunkHeaderReadyForInclusion { .. } => {}
        _ => panic!(),
    }
    match &test.data.client_events[1] {
        ShardsManagerResponse::ChunkCompleted { partial_chunk, shard_chunk } => {
            assert_eq!(partial_chunk.parts().len(), chunk.part_ords().len());
            assert!(shard_chunk.is_some());
        }
        _ => panic!(),
    }
}