Web API functional testing takes an external perspective of the API, using the API Specification and published Use Cases to determine the valid inputs and expected outputs. This is classic "black box" testing, without an intimate knowledge of the API's internal structure. A typical API test developed by QualityLogic's QA Engineers covers the following areas:
- Baseline Tests – These tests exercise each API method in isolation.
- Boundary conditions
- Repeating elements
- Combinations of parameter values
- Default value assumptions (i.e., optional parameters)
- Data types and sizes
- Correct return tags and values
- Task-Oriented Tests – Multiple API calls are made replicating common tasks and real-world scenarios documented in the Use Cases. Characteristics of these API tests are as follows:
- Dependencies between API calls
- Calling order
- Repetitive transactions
- State transitions
- Propagation of data to external systems
- Forced Error Tests - These tests contain typical error scenarios, such as missing required elements, empty content, and content exceeding maximum limits, across a representative sampling of the API methods. Test assertions include:
- Correct error messages
- Fallback behavior
- Transaction rollback behavior
To find out more about QuaityLogic's Web API Testing Services, contact us or request a quote.