From 601135f8f3da5da27bcdd369a7c745b6c32b6f5e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Imobach=20Gonz=C3=A1lez=20Sosa?= Date: Mon, 28 Aug 2023 14:26:06 +0100 Subject: [PATCH] Update from code review --- rust/agama-dbus-server/tests/common/mod.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/rust/agama-dbus-server/tests/common/mod.rs b/rust/agama-dbus-server/tests/common/mod.rs index 883f4ade47..2fb8031397 100644 --- a/rust/agama-dbus-server/tests/common/mod.rs +++ b/rust/agama-dbus-server/tests/common/mod.rs @@ -1,6 +1,7 @@ use agama_lib::{connection_to, error::ServiceError}; use async_std::stream::StreamExt; use std::process::{Child, Command}; +use std::time::Duration; use uuid::Uuid; use zbus::{MatchRule, MessageStream, MessageType}; @@ -80,8 +81,8 @@ impl DBusServer { /// Waits until the D-Bus daemon is ready. // TODO: implement proper waiting instead of just using a sleep fn wait(&self) { - let wait_time = std::time::Duration::from_millis(500); - std::thread::sleep(wait_time); + const WAIT_TIME: Duration = Duration::from_millis(500); + std::thread::sleep(WAIT_TIME); } /// Builds a message stream.