protected virtual void OnAnimationStopped(StoppedReason reason) { var handler = this.AnimationStopped; if (handler != null) { var args = new AnimationEventArgs(); args.StoppedReason = reason; handler(this, args); } }
public static IRunBuilder HitStopEventWithinRange(this IRunBuilder runBuilder, StoppedReason reason, string fileName, int startLine, int endLine, Action <StoppedEvent> postSatisfyAction = null) { return(runBuilder.Event(new StoppedEvent(reason, fileName, startLine, endLine), postSatisfyAction)); }
public static IRunBuilder StoppedEvent(this IRunBuilder runBuilder, StoppedReason reason, string fileName = null, int?lineNumber = null, string text = null) { return(runBuilder.Event(new StoppedEvent(reason, fileName, lineNumber, text))); }
/// <summary> /// Adds an expected stop event within a range of line numbers. If the stop does not occur on <paramref name="targetLine"/>, then perform a step over /// and verify that the debuggee breaks at the <paramref name="targetLine"/>. /// </summary> /// <param name="startLine">The first line number onto which it is acceptable that the stop occurs.</param> /// <param name="targetLine">The line number which is the desired stopping line.</param> public static IRunBuilder ExpectStopAndStepToTarget(this IDebuggerRunner runner, StoppedReason reason, string fileName, int startLine, int targetLine) { return(runner.Expects.HitStopEventWithinRange(reason, fileName, startLine, targetLine, (e) => { if (e.ActualEvent.body.line != targetLine) { runner.Expects.HitStepEvent(fileName, targetLine).AfterStepOver(); } })); }