diff --git a/src/dbus/client.rs b/src/dbus/client.rs index 8de0ba8..fbd3c73 100644 --- a/src/dbus/client.rs +++ b/src/dbus/client.rs @@ -75,6 +75,7 @@ impl Client { } /// The underlying connection. + #[must_use] pub const fn connection(&self) -> &Connection { &self.connection } diff --git a/src/lib.rs b/src/lib.rs index ea2eb70..95337a5 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -24,6 +24,6 @@ mod tests { #[test] fn version_is_not_empty() { - assert!(!VERSION.is_empty()); + assert_ne!(VERSION, ""); } } diff --git a/tests/dbus.rs b/tests/dbus.rs index 35a4a4f..99bc493 100644 --- a/tests/dbus.rs +++ b/tests/dbus.rs @@ -111,7 +111,7 @@ async fn invalid_rules_never_reach_the_daemon() { .await .unwrap_err(); assert!(matches!(err, AppError::Parse(_))); - assert!(mock.calls().is_empty()); + assert_eq!(mock.calls(), Vec::::new(), "nothing may be sent"); } #[tokio::test]