diff --git a/src/content/docs/docs/request-matching.mdx b/src/content/docs/docs/request-matching.mdx index 672514cb..e8cb293e 100644 --- a/src/content/docs/docs/request-matching.mdx +++ b/src/content/docs/docs/request-matching.mdx @@ -24,6 +24,12 @@ WireMock enables flexible definition of a mock API by supporting rich matching o - Multipart/form-data - Client IP (as of WireMock version `3.13.0`) +Most Java examples on this page use static imports from `WireMock`: + +```java +import static com.github.tomakehurst.wiremock.client.WireMock.*; +``` + Here's an example showing all attributes being matched using WireMock's in-built match operators. It is also possible to write [custom matching logic](../extending-wiremock/#custom-request-matchers/) if you need more precise control: diff --git a/src/content/docs/docs/stubbing.mdx b/src/content/docs/docs/stubbing.mdx index 7294d89a..6a874070 100644 --- a/src/content/docs/docs/stubbing.mdx +++ b/src/content/docs/docs/stubbing.mdx @@ -16,6 +16,12 @@ import CloudCallout from '../../../components/CloudCallout.astro'; A core feature of WireMock API mocking is the ability to return canned HTTP responses for requests matching criteria. These are described in detail in [Request Matching](../request-matching/). +Most Java examples on this page use static imports from `WireMock`: + +```java +import static com.github.tomakehurst.wiremock.client.WireMock.*; +``` + ## Basic stubbing