Ejemplo n.º 1
0
        public void DoTheThing(FailingJobParams message,
                               CancellationTokenSource cancellationTokenSource,
                               Action <string> progress)
        {
            Logger.DebugWithLineNumber("'Failing Job Code' Do The Thing method called.");

            var jobProgress = new TestJobProgress
            {
                Text         = WhoAmI + ": This job will soon throw exeception.",
                ConsoleColor = ConsoleColor.DarkRed
            };

            progress(jobProgress.Text);

            throw new Exception(message.Error);
        }
Ejemplo n.º 2
0
		public void DoTheThing(FailingJobParams message,
		                       CancellationTokenSource cancellationTokenSource,
		                       Action<string> progress)
		{
			Logger.DebugWithLineNumber("'Failing Job Code' Do The Thing method called.");

			var jobProgress = new TestJobProgress
			{
				Text = WhoAmI + ": This job will soon throw exeception.",
				ConsoleColor = ConsoleColor.DarkRed
			};

			progress(jobProgress.Text);

			throw new Exception(message.Error);
		}