Function nested_endpoint_matches

Source
pub fn nested_endpoint_matches(
    root: &str,
    parent: &str,
    child: &str,
) -> impl Match
Available on crate feature wiremock only.
Expand description

Match a Django-style nested endpoint in wiremock

This avoids using regular expressions in the calling code. Here

  • root is the base of the Django API, like "/api/v0.2"
  • parent is the parent object, like "bars"
  • child is the nested object, like "foos"

The above specification matches URL paths like

/api/v0.2/bars/1/foos

See the description of NestedEndpointParams for more detail.