fix(doctest): Import harmony instrumentation properly in doc tests
All checks were successful
Run Check Script / check (pull_request) Successful in 1m15s

This commit is contained in:
Jean-Gabriel Gill-Couture 2025-08-29 11:23:11 -04:00
parent 05e7b8075c
commit 0395d11e98

View File

@ -50,6 +50,7 @@ static SUBSCRIBERS: Lazy<Mutex<HashMap<String, Subscriber>>> =
///
/// # Example
/// ```
/// use harmony::instrumentation;
/// instrumentation::subscribe("my_logger", |event| {
/// println!("Event occurred: {:?}", event);
/// });
@ -68,6 +69,8 @@ where
///
/// # Example
/// ```
/// use harmony::instrumentation;
/// use harmony::instrumentation::HarmonyEvent;
/// instrumentation::instrument(HarmonyEvent::HarmonyStarted);
/// ```
pub fn instrument(event: HarmonyEvent) -> Result<(), &'static str> {