protected override void Establish_That()
 {
     TestedClass
     .Stub(tc => tc.Write(Arg <string> .Is.Anything))
     .CallOriginalMethod(OriginalCallOptions.NoExpectation);
     _process = ProcessUtility.LaunchExternalProcess("ping.exe", "www.google.com");
     _process.OutputDataReceived += new DataReceivedEventHandler(OutputDataReceived);
 }
Пример #2
0
 protected override void Because_Of()
 {
     _process = ProcessUtility.LaunchExternalProcess(TestProcess, "", true, false, _processDataCapturer);
 }
Пример #3
0
 protected override void Because_Of()
 {
     _process = ProcessUtility.LaunchExternalProcess(Random.NextString(RandomLength), null);
 }
Пример #4
0
 protected override void Because_Of()
 {
     _beforeLaunchExternalProcess = DateTime.Now;
     _process = ProcessUtility.LaunchExternalProcess(TestProcess, null, true, false, null);
     _afterLaunchExternalProcess = DateTime.Now;
 }
Пример #5
0
 protected override void Because_Of()
 {
     _process = ProcessUtility.LaunchExternalProcess(TestProcess, "/C echo 'Hello World!'", true, true, null);
 }