System.IO.Tests.Directory_CreateDirectory.PathWithInvalidCharactersAsPath_ThrowsArgumentException C# (CSharp) Méthode

PathWithInvalidCharactersAsPath_ThrowsArgumentException() private méthode

        public void PathWithInvalidCharactersAsPath_ThrowsArgumentException()
        {
            var paths = IOInputs.GetPathsWithInvalidCharacters();
            Assert.All(paths, (path) =>
            {
                if (path.Equals(@"\\?\"))
                    Assert.Throws<IOException>(() => Create(path));
                else if (path.Contains(@"\\?\"))
                    Assert.Throws<DirectoryNotFoundException>(() => Create(path));
                else
                    Assert.Throws<ArgumentException>(() => Create(path));
            });
        }
Directory_CreateDirectory