pub mod attribute;
pub mod ef;
pub mod escape;
pub mod helper;
pub mod key;
pub mod signing;
#[macro_export]
#[cfg(test)]
macro_rules! testdata {
() => {{
use std::path::PathBuf;
let mut path = PathBuf::new();
path.push(file!());
path.pop();
path.push("testdata");
path
}};
($f:expr) => {{
let mut path = testdata!();
path.push($f);
path
}};
}
#[cfg(test)]
mod test {
#[test]
fn test_testdata() {
assert_eq!(
testdata!().to_str().unwrap(),
"sw/host/hsmtool/src/util/testdata"
);
assert_eq!(
testdata!("my.file").to_str().unwrap(),
"sw/host/hsmtool/src/util/testdata/my.file"
);
}
}