Thursday, May 23, 2024
 Popular · Latest · Hot · Upcoming
185
rated 0 times [  189] [ 4]  / answers: 1 / hits: 45303  / 9 Years ago, wed, july 1, 2015, 12:00:00

How do I output some information in Postman tests?



console.log(tv4.error);
tests[Valid Data1] = tv4.validate(data1, schema);


console.log() seems to be working but I want to output my info into the same panel where my assertions go (for easier correlation):



enter


More From » testing

 Answers
96

Just make a fake test that passes:



var jsonData = JSON.parse(responseBody);
tests[id = + jsonData.id] = true; // debug message
tests[name = + jsonData.name] = true; // debug message

[#65971] Monday, June 29, 2015, 9 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
allans

Total Points: 336
Total Questions: 120
Total Answers: 119

Location: Peru
Member since Mon, Jun 6, 2022
2 Years ago
;