pub struct ContractValidator { /* private fields */ }๐Deprecated:
Will be extracted to mockforge-contracts crate
Expand description
Contract validator for validating OpenAPI specs against live APIs
Implementationsยง
Sourceยงimpl ContractValidator
impl ContractValidator
Sourcepub fn new() -> Self
๐Deprecated: Will be extracted to mockforge-contracts crate
pub fn new() -> Self
Will be extracted to mockforge-contracts crate
Create a new contract validator with default settings
Sourcepub fn with_strict_mode(self, strict: bool) -> Self
๐Deprecated: Will be extracted to mockforge-contracts crate
pub fn with_strict_mode(self, strict: bool) -> Self
Will be extracted to mockforge-contracts crate
Configure strict validation mode (fails validation on warnings)
Sourcepub fn with_ignore_optional_fields(self, ignore: bool) -> Self
๐Deprecated: Will be extracted to mockforge-contracts crate
pub fn with_ignore_optional_fields(self, ignore: bool) -> Self
Will be extracted to mockforge-contracts crate
Configure whether to ignore optional fields during validation
Sourcepub async fn validate_openapi(
&self,
spec: &OpenApiSpec,
base_url: &str,
) -> ValidationResult
๐Deprecated: Will be extracted to mockforge-contracts crate
pub async fn validate_openapi( &self, spec: &OpenApiSpec, base_url: &str, ) -> ValidationResult
Will be extracted to mockforge-contracts crate
Validate OpenAPI spec against live API
Sourcepub fn compare_specs(
&self,
old_spec: &OpenApiSpec,
new_spec: &OpenApiSpec,
) -> ValidationResult
๐Deprecated: Will be extracted to mockforge-contracts crate
pub fn compare_specs( &self, old_spec: &OpenApiSpec, new_spec: &OpenApiSpec, ) -> ValidationResult
Will be extracted to mockforge-contracts crate
Compare two OpenAPI specs and detect breaking changes
Sourcepub fn generate_report(&self, result: &ValidationResult) -> String
๐Deprecated: Will be extracted to mockforge-contracts crate
pub fn generate_report(&self, result: &ValidationResult) -> String
Will be extracted to mockforge-contracts crate
Generate validation report
Trait Implementationsยง
Auto Trait Implementationsยง
impl Freeze for ContractValidator
impl RefUnwindSafe for ContractValidator
impl Send for ContractValidator
impl Sync for ContractValidator
impl Unpin for ContractValidator
impl UnsafeUnpin for ContractValidator
impl UnwindSafe for ContractValidator
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