AjErl.Tests.ProcessTests.ProcessStartAndRun C# (CSharp) Method

ProcessStartAndRun() private method

private ProcessStartAndRun ( ) : void
return void
        public void ProcessStartAndRun()
        {
            AutoResetEvent handle = new AutoResetEvent(false);
            int count = 0;
            IFunction function = new LambdaFunction(() => { count = 1; return handle.Set(); });
            Process process = new Process();

            process.Start(function);

            handle.WaitOne();

            Assert.AreEqual(1, count);
        }