From ec64e49a08c00b20c507cfdacc9ef2b21403c389 Mon Sep 17 00:00:00 2001 From: IzawGithub Date: Fri, 13 Sep 2024 10:26:54 +0000 Subject: [PATCH 1/2] Add `[Eq, PartialEq]` derive to `ClientError` --- rumqttc/src/client.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rumqttc/src/client.rs b/rumqttc/src/client.rs index a0c907049..60256fd29 100644 --- a/rumqttc/src/client.rs +++ b/rumqttc/src/client.rs @@ -12,7 +12,7 @@ use tokio::runtime::{self, Runtime}; use tokio::time::timeout; /// Client Error -#[derive(Debug, thiserror::Error)] +#[derive(Debug, Eq, PartialEq, thiserror::Error)] pub enum ClientError { #[error("Failed to send mqtt requests to eventloop")] Request(Request), From dc47908465c5d64f30fb00dd20f388a60b3d8f37 Mon Sep 17 00:00:00 2001 From: IzawGithub Date: Fri, 13 Sep 2024 10:36:01 +0000 Subject: [PATCH 2/2] Add change to changelog --- rumqttc/CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/rumqttc/CHANGELOG.md b/rumqttc/CHANGELOG.md index c8c8716a3..7d3974972 100644 --- a/rumqttc/CHANGELOG.md +++ b/rumqttc/CHANGELOG.md @@ -9,6 +9,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Added +* `Eq` and `PartialEq` derive implementation on `ClientError`. * `size()` method on `Packet` calculates size once serialized. * `read()` and `write()` methods on `Packet`. * `ConnectionAborted` variant on `StateError` type to denote abrupt end to a connection