How to make the VSM consult the live system and not return META response when there is no exact match.

Document ID : KB000012142
Last Modified Date : 14/02/2018
Show Technical Document Details
Question:

How to make the VSM consult the live system and not return META response when there is no exact match.

Answer:

This is one example of how we accomplish it.

Modify the service image by adding a new key to the Meta Data in the META response.

Example: ifMeta = true

Save the modified VSI.

In the VSM, VS Image Response Selector step, add the assertion “Ensure Result Contains String”.

In the “Contains String” field add “ifMeta” and, under the “then” field, provide the next step in case the test finds the specified string (if = true). Since we need to consult the live system, the Live Invocation step will be the next step.

Save the modified VSM.

During playback, when the META response is returned, the assertion will be fired and the request will be forwarded to the live system.

 

Additional Information:

Assertions are executed in the order that they appear.

For more information about Assertions: https://docops.ca.com/devtest-solutions/9-5/en/using/using-ca-application-test/using-devtest-workstation-with-ca-application-test/building-test-cases/assertions