1

I am testing an application that constantly communicates with Database. Whenever, there is an error with the Stored Proc execution, whether no data found or incorrect column name or anything else; my karate test just returns 400 error connection timeout exception message (a generic message!).

I have tried perusing through the default logs generated by Karate, but the errors are not detailed & accurate enough.

What i want is that, Karate should report the error in detailed form. Such as, what caused the error? whether it is incorrect parameters in Stored proc? or DB Table non- existent? or could not connect to DB., Invalid User ID, etc. How can i achieve that in Karate?

Shrikant
  • 91
  • 1
  • 7

1 Answers1

1

Karate is for HTTP testing and for that it does a great job reporting errors.

I'm guessing you used a custom Java utility to make database calls and please note that you are completely in control of that code and Karate has nothing to do with it. For more details, please see this answer: https://stackoverflow.com/a/46964277/143475 and also this one: https://stackoverflow.com/a/52078427/143475

If you didn't write the code to connect to the database, catch hold of the person who did - and ask these questions to him / her. All the best !

Peter Thomas
  • 54,465
  • 21
  • 84
  • 248