API Testing · Junior · Question 34 of 75
What is negative API testing?
- 1Sending invalid or unexpected input and checking it's rejected well
- 2Removing tests that fail so the suite stays green
- 3Testing only the requests that are expected to fail in production
Show the answer
Correct answer: Sending invalid or unexpected input and checking it's rejected well
Explanation
Missing required fields, wrong types, too long strings and invalid IDs should give clear 4xx errors, not crashes or saved bad data.