public async Task ProcessRunner_RunProcessAsync_ArpTest_InstantTimeout()
        {
            var arpCommandPath = _fileSystem.ArpCommandPath();
            var args           = new[] { "-a" };

            var result = await _processRunner.RunProcessAsync(arpCommandPath, args, new TimeSpan(10));

            result.Should().NotBeNull().And.Subject.Should().BeOfType(typeof(ProcessResult));
            result.Completed.Should().BeFalse();
            result.Output.Trim().Should().BeNullOrEmpty();
        }
Example #2
0
        public void ProcessRunner_RunProcessAsync_Null_Args()
        {
            var arpCommandPath = _fileSystem.ArpCommandPath();

            Func <Task> act = async() => await _processRunner.RunProcessAsync(arpCommandPath, null, null);

            act.Should().Throw <ArgumentNullException>().And.ParamName.Should().Be("args");
        }
        public void FileSystem_ArpCommandPath_FileExists()
        {
            var arpCommandPath = _fileSystem.ArpCommandPath();

            _fileSystem.FileExists(arpCommandPath).Should().BeTrue();
        }