除了合同验证之外,Pact 测试还有哪些好处?
我想更详细地了解这个契约测试。我知道通过契约测试我们可以验证请求和响应,并且主要是消费者驱动的。除了这个还有什么好处吗?如果是,有人可以帮助我详细了解这一点吗?
I want to know this pact testing in more details. I know by pact testing we can verify request and response and mostly it is consumer driven. Are there any more benefits other than this. If yes, can someone help me to understand this in details?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
在我看来,主要的好处是提供者和消费者之间保持同步,这样您就可以自动检测更改何时违反合同,然后不部署它以避免消费者方面出现问题。
安装和配置包后,编写测试并不那么困难,并且为您的应用程序增加了一层安全性......
In my opinion, the principal benefit is to have in sync between the providers and consumers, this way you can automatically detect when a change breaks the contract and then don't deploy it to avoid issues in the consumer side.
When pack is installed and configured, writing tests is not so difficult, and is a plus layer of security for your app...
最大的好处之一是您可以减少需要执行的集成测试量,而不会增加错误的风险。
以下是一些好处:https://docs.pact.io/faq/concinceme
One of the biggest benefits is that you can reduce the amount of integration testing that you need to do, without increasing the risk of bugs.
Here are some of the benefits: https://docs.pact.io/faq/convinceme