你的位置: 码友网首页 / 资讯源列表 / Readable and clear tests for ASP.NET Core services

关于[Readable and clear tests for ASP.NET Core services]的摘要:

For the last year, I’ve had an opportunity to work quite a lot with Component Tests for microservices built with ASP.NET Core. The vocabulary related to testing is very vague and terms like Unit, Component, and Integration tests can be interpreted differently based on the context, so let me explain first what I mean by Component Tests. It’s a kind of test that treats your whole service as a black box. You can communicate with your system during the tests only through the publicly available interfaces (REST API, GRPC, Messaging, etc.). You are also not allowed to mock anything besides the external dependencies. Those external dependencies can be mocked by replacing the real component with an in-memory counterpart inside the DI container.

原文地址: https://cezarypiatek.github.io/post/component-tests-scenarios/

收录时间: 2021-08-11 浏览量: 1138 分类: ASP.NET Core

| 0 收藏 | 0