public void EnumListTest() { var items = EnumUtil.EnumList <DivisionLeagTypes>(); Enum en = items[1]; Assert.AreEqual(DivisionLeagTypes.AE.GetType().Name, items[1].GetType().Name); }
private void SetBorderCorners() { List <BorderCorners> items = EnumUtil.EnumList <BorderCorners>(); for (int i = 0; i < items.Count; i++) { if (GetFlag(items[i])) { Button b = GetButton(items[i]); b.BackColor = IsSelected(b.BackColor) ? _normalState : _selectedState; } } }
public string DisplaySelection() { StringBuilder sb = new StringBuilder(); List <BorderCorners> items = EnumUtil.EnumList <BorderCorners>(); for (int i = 0; i < items.Count; i++) { if (_borderCorners.HasFlag(items[i])) { sb.Append(Enum.GetName(typeof(BorderCorners), items[i]).ToString() + " "); } } return(sb.ToString()); }
public void EnumListCountTest() { var items = EnumUtil.EnumList <DivisionLeagTypes>(); Assert.AreEqual(8, items.Count); }