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

PathAlreadyExistsAsFile() private méthode

private PathAlreadyExistsAsFile ( ) : void
Résultat void
        public void PathAlreadyExistsAsFile()
        {
            string path = GetTestFilePath();
            File.Create(path).Dispose();

            Assert.Throws<IOException>(() => Create(path));
            Assert.Throws<IOException>(() => Create(IOServices.AddTrailingSlashIfNeeded(path)));
            Assert.Throws<IOException>(() => Create(IOServices.RemoveTrailingSlash(path)));
        }
Directory_CreateDirectory