diff --git a/iced_layershell/tests/test_macro.rs b/iced_layershell/tests/test_macro.rs index 1661b14..b837549 100644 --- a/iced_layershell/tests/test_macro.rs +++ b/iced_layershell/tests/test_macro.rs @@ -1,5 +1,5 @@ -use iced_layershell::actions::IsSingleton; -use iced_layershell::{to_layer_message, windowinfo_marker}; +use iced_layershell::actions::{IsSingleton, MainWindowInfo}; +use iced_layershell::{to_layer_message, WindowInfoMarker}; #[test] fn test_layer_message_macro() { @@ -15,7 +15,7 @@ fn test_layer_message_macro() { #[test] fn test_layersingleton_derive() { #[allow(unused)] - #[derive(windowinfo_marker)] + #[derive(WindowInfoMarker)] enum SingleToneTest { #[singleton] SingleTon, @@ -26,9 +26,15 @@ fn test_layersingleton_derive() { }, #[singleton] SingleTonThird(i32), + #[main] + Main, } assert!(SingleToneTest::SingleTon.is_singleton()); assert!(!SingleToneTest::NotSingleTon.is_singleton()); assert!(SingleToneTest::SingleTonTwo { field: false }.is_singleton()); assert!(SingleToneTest::SingleTonThird(10).is_singleton()); + assert!(matches!( + MainWindowInfo.try_into().unwrap(), + SingleToneTest::Main + )) }