0

I am building a VuGen http script to test a RESTful webservice. I've created the happy path test case, but I need to test also a scenario where I would expect a 500 Internal Server Error.

Does VuGen support assertions in any way?

Nacho321
  • 1,911
  • 7
  • 33
  • 55

2 Answers2

1

web_reg_find() is the function you want. Refer to the VuGen documentation.

Michael Galos
  • 1,065
  • 3
  • 13
  • 27
0

You are engaging in functional testing with a performance testing tool. You may have a philosophical conflict here

James Pulley
  • 5,606
  • 1
  • 14
  • 14
  • When you do a big load test, it is usefull to know if you have 5% of http status 500 in the responses. What the point of having a good througput, if what you receive is garbage ? And sometimes, you experience errors only during big load, that you can't reproduce with traditional functionnal test. ( for instance a firewall with a limited number of concurrent connections) – Florian Prud'homme Oct 24 '20 at 18:29
  • HTTP Status codes are collected automatically with LoadRunner on each request. No additional code is required, You also have the option of stripping the logs on the web tier at the end of the test. If you include the w3c time-taken field in your logs, then you also have a measurement of time with your HTTP status code – James Pulley Oct 24 '20 at 20:28
  • Yes of course. But the built-in capacities are not sufficient for some real life scenarios. If you want to emulate a terminal which will retry 3 times a login in case of http errors, and the third time, it is a successful http 200, and then continue with some other transactions, you will need to tick "continue on error" in your settings. Another example : you could get an http 520 because the server want to inform you that your token is expired, and what you need to do is asking for a new token, and then you can continue the scenario until the payment step. – Florian Prud'homme Oct 25 '20 at 21:45