use std::convert::Infallible; use mockall::mock; use xml_stinks::deserializer::{Deserializer, Error, IgnoreEnd, MaybeStatic}; use xml_stinks::tagged::TagStart; use xml_stinks::DeserializeTagged; mock! { pub Deserializer {} impl Deserializer for Deserializer { fn de_tag( &mut self, tag_name: &str, ignore_end: IgnoreEnd, ) -> Result>; fn de_tag_with( &mut self, tag_name: &str, ignore_end: IgnoreEnd, deserialize: Func, ) -> Result> where TOutput: MaybeStatic, Err: std::error::Error + Send + Sync + 'static, Func: FnOnce(&TagStart, &mut MockDeserializer) -> Result + MaybeStatic; fn de_tag_list( &mut self, tag_name: Option ) -> Result, Error> where De: DeserializeTagged, TagName: AsRef + MaybeStatic; fn de_text(&mut self) -> Result>; fn skip_to_tag_start(&mut self, tag_name: &str) -> Result<(), Error>; fn skip_to_tag_end(&mut self, tag_name: &str) -> Result<(), Error>; } }