#![doc = include_str!("../README.md")]
#![forbid(unsafe_code)]
#![warn(missing_docs)]
pub mod certificate;
pub mod export;
#[doc(hidden)]
pub mod gzip;
pub mod import;
mod lotw;
mod memory;
pub mod options;
mod pkcs12;
mod protected_key;
pub mod qso;
pub mod records;
pub mod request;
pub mod signed_log;
pub mod signing;
pub mod station;
pub mod store;
pub mod tbk;
pub mod upload;
mod xml;
pub const VERSION: &str = env!("CARGO_PKG_VERSION");
#[cfg(test)]
mod tests {
use super::VERSION;
#[test]
fn version_is_semantic() {
let (release, beta) = match VERSION.split_once('-') {
Some((release, pre)) => (release, Some(pre)),
None => (VERSION, None),
};
let parts: Vec<&str> = release.split('.').collect();
assert_eq!(parts.len(), 3, "{VERSION}");
assert!(parts.iter().all(|p| p.parse::<u32>().is_ok()), "{VERSION}");
if let Some(pre) = beta {
let n = pre.strip_prefix("beta.").expect(VERSION);
assert!(n.parse::<u32>().is_ok_and(|n| n > 0), "{VERSION}");
}
}
}