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: test.rs
    path of file: ./repos/rnote/crates/rnote-cli/src
    
    the code of the file until where you have to start completion: // Imports
use crate::{cli, validators};
use rnote_engine::engine::EngineSnapshot;
use std::path::{Path, PathBuf};

pub(crate) async fn run_test(rnote_files: &[PathBuf]) -> anyhow::Result<()> {
    for rnote_file in rnote_files.iter() {
        validators::file_has_ext(rnote_file, "rnote")?;
        let file_disp = rnote_file.display().to_string();
        let progressbar = cl
    
pub(crate) async fn run_test(rnote_files: &[PathBuf]) -> anyhow::Result<()> {
    for rnote_file in rnote_files.iter() {
        validators::file_has_ext(rnote_file, "rnote")?;
        let file_disp = rnote_file.display().to_string();
        let progressbar = cli::new_progressbar(format!("Testing file \"{file_disp}\""));

        if let Err(e) = test_file(rnote_file).await {
            let abandon_msg = format!("Test failed, Err: {e:?}");
            if progressbar.is_hidden() {
                println!("{abandon_msg}");
            }
            progressbar.abandon_with_message(abandon_msg);
            return Err(e);
        } else {
            let finish_msg = format!("Test succeeded for file \"{file_disp}\"");
            if progressbar.is_hidden() {
                println!("{finish_msg}");
            }
            progressbar.finish_with_message(finish_msg);
        }
    }

    Ok(())
}