Function get_test_dir_name

Source
pub fn get_test_dir_name(modpath: &str, funcname: &str) -> String
Expand description

Get a testdir name given a modpath and funcname

ยงExample

Callers should use std::module_path and function_name macros for the arguments:

use target_test_dir::{named, get_test_dir_name};

#[named]
fn my_func() -> String {
    get_test_dir_name(module_path!(), function_name!())
}

assert_eq!(
    my_func(),
    // Note: for doc examples the crate name is `rust_out`:
    "rust_out-my_func",
);