예제 #1
0
 private static void StepEnd(Step step)
 {
     switch (step.State)
     {
         case StepState.Failed:
             WriteLine("Failed: " + step.Exception.Message, 012);
             break;
         case StepState.Passed:
             WriteLine(Enum.GetName(typeof(StepState), step.State), 010);
             break;
         case StepState.Skipped:
             WriteLine(Enum.GetName(typeof(StepState), step.State), 014);
             break;
     }
 }
예제 #2
0
 /// <summary>
 /// Adds a step.
 /// </summary>
 /// <param name="givenStep">The given step.</param>
 internal virtual void AddStep(Step givenStep)
 {
     this.Steps.Add(givenStep);
 }
예제 #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="StepViewModel"/> class.
 /// </summary>
 /// <param name="step">The step.</param>
 public StepViewModel(Step step)
 {
     this.StepName = step.Label;
 }
 protected void I_create_an_instance()
 {
     step = GetDummyStep();
     viewModel = new StepViewModel(step);
 }
예제 #5
0
 /// <summary>
 /// Called when the step ends
 /// </summary>
 /// <param name="step">The step.</param>
 private void OnStepEnd(Step step)
 {
     if (this.StepEnd != null)
     {
         this.StepEnd(step);
     }
 }
예제 #6
0
 /// <summary>
 /// Called when the step begins
 /// </summary>
 /// <param name="step">The step.</param>
 private void OnStepBegin(Step step)
 {
     if(this.StepBegin != null)
     {
         this.StepBegin(step);
     }
 }