Beispiel #1
0
        public async Task CreateGroup_AddToRoot()
        {
            var groupName = "Test";

            // Add the group.
            await ABSRegistry.CreateGroupAsync(groupName);

            // Make sure that group exists.
            CollectionAssert.AreEqual(groupName.ToCharArray(), ABSRegistry.RegistryItems[0].Name);
        }
Beispiel #2
0
        public async Task CreateGroup_InOtherGroup()
        {
            // Set up the registry.
            await ABSRegistry.AddItemToRootAsync(new Group("Test1".ToCharArray()));

            await ABSRegistry.AddItemToRootAsync(new Group("Test2".ToCharArray()));

            await ABSRegistry.AddItemToRootAsync(new Group("Test3".ToCharArray()));

            // Add the group.
            await ABSRegistry.CreateGroupAsync("Test1/NewGroup");

            // Make sure that group exists.
            CollectionAssert.AreEqual("NewGroup".ToCharArray(), (ABSRegistry.RegistryItems[0] as Group).InnerItems[0].Name);
        }