我已经构建了一些规格方案来测试HTTP REST接口的功能。当我单独运行功能时,它们工作正常,但是当一起运行时,有些情况有时会失败。失败是没有REST接口Web服务器的答复。
所有功能的第一步是启动REST Interface Web服务器,但是我认为,如果其他方案仍在运行,或者还没有完全完成并且听力端口不能绑定,则可能会失败。
有没有办法确保彼此之后的不同功能运行良好?
I have built some SpecFlow scenarios to test features of a HTTP REST interface. When I run the features separately, they work fine, but when run all together, some of the scenarios sometimes fail. The failure is that there is no reply from the REST interface webserver.
The first step of all features is to start the REST interface webserver, but I reckon this can fail if another scenario is still running, or not yet completely finished and the listening port cannot be bound.
Is there a way to make sure the different features run nicely after eachother?
发布评论
评论(1)
我在 Xunit.runner.json 文件,并添加
到配置中。现在只在当时运行一个Specflow测试。
I found the answer on the xUnit documentation site. I added a
xunit.runner.json
file and addedto the config. Only one SpecFlow test is run at the time now.