知识卡片

普通读书笔记卡 · 3227

集成测试跨外部依赖边界

理解等级:中级

集成测试聚焦本服务与外部依赖之间的边界:请求是否发到正确地址、载荷是否正确、返回值能否被本服务解释。它不必覆盖整个业务链,也不应把被依赖服务自身的正确性当成当前模块的测试责任;测试范围由被验证的边界决定。

这张卡片看不懂?

已有反馈 · 0 / 10 条

    还没有人提交反馈。

    在整书笔记中的位置

    原书出处 · 1 处

    • · 查看原书依据

      Integration tests in our definition are tests across boundaries between the module being developed and any external dependencies. Integration tests are a type of service test and can be seen in the test pyramid image in Figure 2-3. When performing integration testing, you want to confirm that the communication across the boundary is correct; i.e., your service can correctly communicate with another service that is external to it.

    参考来源

    - 位置:《Mastering API Architecture》第2章《Testing APIs》之《API Integration Testing》(源文件:_epub-src/OEBPS/ch02.xhtml) - 结论依据:原文定义集成测试为跨被开发模块与外部依赖的边界,并列出 URL、请求体和响应处理等具体核验点。 - 原始内容:Integration tests in our definition are tests across boundaries between the module being developed and any external dependencies. Integration tests are a type of service test and can be seen in the test pyramid image in Figure 2-3 . When performing integration testing, you want to confirm that the communication across the boundary is correct; i.e., your service can correctly communicate with another service that is external to it.