System.Diagnostics.Tests.ProcessTests.TestStartOnWindowsWithBadFileFormat C# (CSharp) Метод

TestStartOnWindowsWithBadFileFormat() приватный Метод

private TestStartOnWindowsWithBadFileFormat ( ) : void
Результат void
        public void TestStartOnWindowsWithBadFileFormat()
        {
            string path = GetTestFilePath();
            File.Create(path).Dispose();

            Win32Exception e = Assert.Throws<Win32Exception>(() => Process.Start(path));
            Assert.NotEqual(0, e.NativeErrorCode);
        }
ProcessTests