Configure the JMeter XPath2 Assertion assertions: properties, defaults, and practical usage notes for building reliable load tests.
Part of the Assertions category. Also documented in context in the full Component Reference.

The XPath2 Assertion tests a document for well formedness. Using โ/โ will match any well-formed
document, and is the default XPath2 Expression.
The assertion also supports boolean expressions, such as โcount(//*error)=2โ.
Some sample expressions:
//title[text()='Text to match']- matches<title>Text to match</title>anywhere in the response/title[text()='Text to match']- matches<title>Text to match</title>at root level in the response
| Name | Required | Description |
|---|---|---|
| Namespaces aliases list | No | List of namespaces aliases you want to use to parse the document, one line per declaration. You must specify them as follow: prefix=namespace. This implementation makes it easier to use namespaces than with the old XPathExtractor version. |
| XPath2 Assertion | Yes | XPath to match in the document. |
| Invert assertion | No | Will fail if xpath expression returns true or matches, succeed otherwise |
| Namespace aliases list | No | List of namespace aliases prefix=full namespace (one per line) |