Beispiel #1
0
        public async Task CreateFolderWorks()
        {
            var folderName = "Test";
            var folderOne  = await TestRootFolder.CreateDirectoryAsync(folderName);

            var folders = await TestRootFolder.EnumerateDirectoriesAsync();

            var items = await TestRootFolder.EnumerateItemsAsync();

            Assert.Collection(folders, d => Assert.Equal(folderOne, d));
            Assert.Single(items);

            var item = await TestRootFolder.GetDirectoryAsync(folderName);

            Assert.NotNull(item);
            item = await TestRootFolder.GetDirectoryAsync("notExistent");

            Assert.Null(item);
        }