pub struct MockServerDetector;Expand description
Detects if a target URL is a MockForge mock server
Implementations§
Source§impl MockServerDetector
impl MockServerDetector
Sourcepub async fn detect(target_url: &str) -> Result<MockServerInfo>
pub async fn detect(target_url: &str) -> Result<MockServerInfo>
Check if a URL points to a MockForge mock server
Makes a request to /__mockforge/info endpoint to detect MockForge servers.
Sourcepub fn looks_like_mock_server(target_url: &str) -> bool
pub fn looks_like_mock_server(target_url: &str) -> bool
Quick check if target looks like a mock server (without HTTP request)
Auto Trait Implementations§
impl Freeze for MockServerDetector
impl RefUnwindSafe for MockServerDetector
impl Send for MockServerDetector
impl Sync for MockServerDetector
impl Unpin for MockServerDetector
impl UnwindSafe for MockServerDetector
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more