Works fine for me using
${A}|${B}|c
where A=a and b=b with input of either a (succeeds) or d (fails)
Are you sure the output contains the correct data?
On 11/01/07, Ivan Rancati <[EMAIL PROTECTED]> wrote:
An API I am testing can return one of several strings, that look like this
61A6C22QXPUZA6G2XD
FJKTCS7597QWBZ29Y9
8PGUE8J7NM72AWMA8H
DQS23CB9J4MXJ4NWGW
CBMX24WPUKJHW32FFS
AQ4PA3VGAGJRB2A191
8BF98WM3RFYT4J6ZJ9
I have a variable for each of these possible matches, and in the Response
Assertion, I want the test to pass if one of the above 7 strings is
returned.
So my regex looks like
${mn6ac1}|${mn6ac2}|${mn6ac3}|${mn6ac4}|${mn6ac5}|${mn6ac6}|${mn6ac7}
If I run it, however, it looks like the pipe characters are not interpreted
as "alternation"
(see http://www.regular-expressions.com/alternation.html)
but are literally interpreted, as the Assertion Results listener shows
Test failed, text expected to match
/61A6C22QXPUZA6G2XD|FJKTCS7597QWBZ29Y9|8PGUE8J7NM72AWMA8H|.....
I have tried to group with parenthesis too, but that does not work either.
All suggestions welcome
Ivan
--
View this message in context:
http://www.nabble.com/Matching-one-of-several-strings-in-Response-Assertion-tf2959081.html#a8278091
Sent from the JMeter - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]