When to Use Service Testing?
When to use service testing?
Service testing is most valuable when any one or more of the following conditions apply:
- Your application has more than a handful of services
- The services are evolving fast
- You want to release services independently
- The service dependency graph is dense on either the consumer or producer side
Advantages of service testing include:
- Shift integration testing left
- Problems can be identified before submitting your code
- You do not need to wait for E2E regression tests to validate existing functionality
- Enables independent release of services
- Testing complexity is lower than E2E tests
When service testing may not add value?
Service testing may not be appropriate in the following situation:
- For applications that are functionally like monoliths, with a main service, and a few peripheral services that are not used extensively. For these applications, end-to-end API testing may be a better test strategy than service testing, and API Studio's end-to-end testing capabilities are better suited for these applications.
- If you cannot control the state your service depends on to generate predictable responses.
When to use API Studio?
API Studio currently supports the following use cases:
- The application uses REST or gRPC protocols
- You need functional validation of APIs beyond just contract testing
Additional requirements include:
- Mock data can be stored in Mesh Dynamics cloud storage
- The service being developed must be running locally, either in your IDE or in a container. Producer services could be running either in a cluster or locally.