/// <summary>
        /// Basic CRUD operations test.
        /// </summary>
        /// <param name="exchangeService"></param>
        public static async Task CreateReadUpdateDeleteMailFolder(ExchangeService exchangeService)
        {
            MailFolder inbox = await exchangeService.GetAsync <MailFolder>(
                new EntityPath(WellKnownFolderName.Inbox.ToString(),
                               typeof(MailFolder)));

            foreach (MailFolder folder in await exchangeService.FindFolders(inbox.Id, new MailFolderView(10, 0)))
            {
                await folder.DeleteAsync();
            }

            MailFolder folder1 = new MailFolder(exchangeService)
            {
                DisplayName = "MyTestFolder1"
            };

            Assert.IsNull(folder1.Id);
            await folder1.SaveAsync(inbox);

            Assert.IsNotNull(folder1.Id);

            MailFolder folder2 = new MailFolder(exchangeService);

            folder2.DisplayName = "MyTestFolder2";

            Assert.IsNull(folder2.Id);
            await folder2.SaveAsync(inbox);

            Assert.IsNotNull(folder2.Id);

            folder2 = await folder2.Move(folder1.Id);

            folder1.DisplayName = "NewDisplayName";
            await folder1.UpdateAsync();

            Assert.AreEqual(
                "NewDisplayName",
                folder1.DisplayName);

            Assert.AreEqual(
                folder1.Id,
                folder2.ParentFolderId);

            await folder2.DeleteAsync();

            Assert.IsNull(folder2.DisplayName);
            Assert.IsNull(folder2.Id);

            await folder1.DeleteAsync();

            Assert.IsNull(folder1.DisplayName);
            Assert.IsNull(folder1.Id);
        }
        /// <summary>
        /// Basic CRUD operations test.
        /// </summary>
        /// <param name="exchangeService"></param>
        public static void CreateReadUpdateDeleteMailFolder(ExchangeService exchangeService)
        {
            exchangeService.MailboxId = new MailboxId(AppConfig.MailboxA);

            foreach (MailFolder folder in exchangeService.FindFolders(WellKnownFolderName.Inbox, new FolderView(10)))
            {
                folder.Delete();
            }

            MailFolder folder1 = new MailFolder(exchangeService)
            {
                DisplayName = "MyTestFolder1"
            };

            Assert.IsNull(folder1.Id);
            folder1.Save(WellKnownFolderName.Inbox);
            Assert.IsNotNull(folder1.Id);

            MailFolder folder2 = new MailFolder(exchangeService);

            folder2.DisplayName = "MyTestFolder2";

            Assert.IsNull(folder2.Id);
            folder2.Save(WellKnownFolderName.Inbox);
            Assert.IsNotNull(folder2.Id);

            Thread.Sleep(5000);

            folder2 = folder2.Move(folder1.Id);

            folder1.DisplayName = "NewDisplayName";
            folder1.Update();

            Assert.AreEqual(
                "NewDisplayName",
                folder1.DisplayName);

            Assert.AreEqual(
                folder1.Id,
                folder2.ParentFolderId);

            folder2.Delete();
            Assert.IsNull(folder2.DisplayName);
            Assert.IsNull(folder2.Id);

            folder1.Delete();
            Assert.IsNull(folder1.DisplayName);
            Assert.IsNull(folder1.Id);
        }