通过AllowedStatusCodes()
方法可以设置允许的状态码:
var audit = new Auditor(() => VirtualClusterWith
.Nodes(10)
.ClientCalls(r => r.FailAlways(400))
.StaticConnectionPool()
.Settings(s => s.DisablePing().MaximumRetries(0))
);
audit = await audit.TraceCalls(
new ClientCall {
{ BadResponse, 9200 }
},
new ClientCall(r => r.AllowedStatusCodes(400)) {
{ HealthyResponse, 9201 }
}
);
发表评论
登录用户才能发表评论, 请 登 录 或者 注册