From f0ccda7d7402c532bce560fe743c07d1444b80ce Mon Sep 17 00:00:00 2001 From: SoniEx2 Date: Mon, 13 Sep 2021 23:21:23 -0300 Subject: Ditch Duration in DataSourceBase --- src/data/effective/tests.rs | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'src/data/effective') diff --git a/src/data/effective/tests.rs b/src/data/effective/tests.rs index dab503f..9d0a21f 100644 --- a/src/data/effective/tests.rs +++ b/src/data/effective/tests.rs @@ -17,8 +17,6 @@ //! Unit tests for the effective module. use std::collections::BTreeSet; -use std::error; -use std::time::Duration; use impl_trait::impl_trait; use url::Url; @@ -26,6 +24,7 @@ use url::Url; use crate::data::{ DataSource, DataSourceBase, + Update, }; use crate::data::kinds::{ InstanceBaseUrl, @@ -40,13 +39,10 @@ struct EffectiveTester; impl_trait! { impl EffectiveTester { - /// Always updates successfully, with an unknown refresh interval. + /// Always updates with no stats. impl trait DataSourceBase { - fn update(&mut self) -> ( - Option, - Result<(), Box>, - ) { - (None, Ok(())) + fn update(&mut self) -> Update { + Update::default() } fn exists(&self) -> bool { -- cgit 1.4.1