英文:
Hoverfly API Simulations with Golang repositories: how to get started
问题
我刚刚开始尝试使用Hoverfly,我有一个使用Golang的后端,调用了一些第三方API,我需要创建模拟。我知道Hoverfly有Java和Py的绑定,并且我找到了一些使用Hoverfly的教程。我可能在一个非常微小的地方遗漏了一点,一旦我创建了模拟(通过捕获模式),下一步是什么?我只需创建使用它们的集成测试吗?我需要将这里的go包导入到我的存储库中吗?我在示例文件夹中寻找一些用法示例,但看到的更多是.py的示例。有没有我完全错过的可用示例?
谢谢
英文:
I have just started to experiment with Hoverfly and I have a Golang backend calling a number of 3rd party APIs for which I would need to create simulations. I am aware that Hoverfly has Java and Py bindings and I have come across a number of tutorials using Hoverfly with both. I think I am possibly missing very trivial point here, once I have created the simulations (via the Capture Mode), what is the next step? Do I simply create integration tests making use of them? Do you import the go package here into my repository? I was looking for some sample usages in the examples folder and I have seen more .py driven ones. Is there any available example that I totally missed out?
Thank you
答案1
得分: 1
对于Golang的测试,你可以查看hoverfly项目中的功能测试:https://github.com/SpectoLabs/hoverfly/tree/master/functional-tests,它使用hoverfly来测试hoverfly!
英文:
For Golang testing, you can have a look at the functional tests in the hoverfly project: https://github.com/SpectoLabs/hoverfly/tree/master/functional-tests, it’s using hoverfly to test hoverfly!
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论