本文整理汇总了C#中Step.EnsureComplete方法的典型用法代码示例。如果您正苦于以下问题:C# Step.EnsureComplete方法的具体用法?C# Step.EnsureComplete怎么用?C# Step.EnsureComplete使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Step
的用法示例。
在下文中一共展示了Step.EnsureComplete方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: EnsureComplete_should_throw_if_minimum_count_not_met
public void EnsureComplete_should_throw_if_minimum_count_not_met()
{
var step = new Step(Times.Once());
Assert.Throws<SequenceException>(() => step.EnsureComplete(""));
Assert.That(step.Complete, Is.False);
}
示例2: EnsureComplete_should_not_throw_if_minimum_and_maximum_count_met
public void EnsureComplete_should_not_throw_if_minimum_and_maximum_count_met()
{
var step = new Step(Times.Once());
step.CountCall();
step.EnsureComplete("");
Assert.That(step.Complete, Is.True);
}
示例3: Reset_should_clear_call_count_and_Complete_status
public void Reset_should_clear_call_count_and_Complete_status()
{
var step = new Step(Times.Once());
step.CountCall();
step.EnsureComplete("");
step.Reset();
Assert.That(step.Complete, Is.False);
step.CountCall();
}
示例4: Should_throw_if_CountCall_invoked_after_step_is_complete
public void Should_throw_if_CountCall_invoked_after_step_is_complete()
{
var step = new Step(Times.AtMostOnce());
step.EnsureComplete("");
Assert.Throws<SequenceException>(step.CountCall);
}
示例5: Should_not_be_complete_if_call_count_less_than_minimum
public void Should_not_be_complete_if_call_count_less_than_minimum()
{
var step = new Step(Times.AtLeastOnce());
Assert.Throws<SequenceException>(() => step.EnsureComplete(""));
}