From 7a1d6b374d1a1b68a50d9cdab62a1ebd554ec70a Mon Sep 17 00:00:00 2001 From: Ronald Holshausen Date: Wed, 25 Oct 2023 08:48:35 +1100 Subject: [PATCH] chore(FFI): Update the doc comment for multiple query parameter values with a matcher #332 --- rust/pact_ffi/src/mock_server/handles.rs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/rust/pact_ffi/src/mock_server/handles.rs b/rust/pact_ffi/src/mock_server/handles.rs index 8f5d93782..17d8bb52e 100644 --- a/rust/pact_ffi/src/mock_server/handles.rs +++ b/rust/pact_ffi/src/mock_server/handles.rs @@ -765,6 +765,13 @@ pub extern fn pactffi_with_query_parameter( /// ``` /// See [IntegrationJson.md](https://github.com/pact-foundation/pact-reference/blob/master/rust/pact_ffi/IntegrationJson.md) /// +/// If you want the matching rules to apply to all values (and not just the one with the given +/// index), make sure to set the value to be an array. +/// +/// ```c +/// const char* value = "{\"value\":[\"2\"], \"pact:matcher:type\":\"regex\", \"regex\":\"\\\\d+\"}"; +/// pactffi_with_query_parameter_v2(handle, "id", 0, value); +/// ``` /// # Safety /// The name and value parameters must be valid pointers to NULL terminated strings. /// ```