示例#1
0
        public void MenuItemCollection_AddRange_Invoke_Success(MenuItem[] items)
        {
            var menu       = new SubMenu(new MenuItem[0]);
            var collection = new Menu.MenuItemCollection(menu);

            collection.AddRange(items);
            Assert.Equal(items.Length, collection.Count);
            Assert.Equal(items, collection.Cast <MenuItem>());
        }