Diffstat (limited to 'tests/common/protocol/sequence.rs')
-rw-r--r--tests/common/protocol/sequence.rs14
1 files changed, 7 insertions, 7 deletions
diff --git a/tests/common/protocol/sequence.rs b/tests/common/protocol/sequence.rs
index f4f0abf..9b3f6b2 100644
--- a/tests/common/protocol/sequence.rs
+++ b/tests/common/protocol/sequence.rs
@@ -1,7 +1,7 @@
use mockall::mock;
use treaty::{
any::{any_trait, TypeName},
- effect::{Effect, Future},
+ effect::{Effect, Effective, ErasedEffective},
protocol::DynWalker,
protocol::{
visitor::{
@@ -35,8 +35,8 @@ impl<'ctx, E: Effect> Sequence<'ctx, E> for MockSequenceVisitor<E> {
fn visit<'a>(
&'a mut self,
scope: DynSequenceScope<'a, 'ctx, E>,
- ) -> Future<'a, VisitResult<DynSequenceScope<'a, 'ctx, E>>, E> {
- E::ready(self.visit()(&(), scope))
+ ) -> ErasedEffective<'a, VisitResult<DynSequenceScope<'a, 'ctx, E>>, E> {
+ E::ready(self.visit()(&(), scope)).into_erased()
}
}
@@ -48,11 +48,11 @@ mock! {
}
impl<'ctx, E: Effect> SequenceScope<'ctx, E> for MockSequenceScope<E> {
- fn size_hint(&mut self) -> Future<'_, (usize, Option<usize>), E> {
- E::ready(self.size_hint())
+ fn size_hint(&mut self) -> ErasedEffective<'_, (usize, Option<usize>), E> {
+ E::ready(self.size_hint()).into_erased()
}
- fn next<'a>(&'a mut self, visitor: DynVisitor<'a, 'ctx>) -> Future<'a, Flow, E> {
- E::ready(self.next(visitor))
+ fn next<'a>(&'a mut self, visitor: DynVisitor<'a, 'ctx>) -> ErasedEffective<'a, Flow, E> {
+ E::ready(self.next(visitor)).into_erased()
}
}