// List all badges private void DisplayAllBadges() { Console.Clear(); foreach (KeyValuePair <int, KomodoBadge> pair in _badgeRepo.GetBadgeDictionary()) { DisplayBadgeInfo(pair.Value); } }
private void ListBadges() { Console.Clear(); Dictionary <int, KomodoBadge> badgeDictionary = _badgeRepo.GetBadgeDictionary(); string tableHeaders = String.Format("{0,-20} {1,-40}", "ID:", "Accessible Doors:\n\n"); Console.WriteLine(tableHeaders); foreach (var badge in badgeDictionary.Values) { string tableBody = String.Format("{0,-20}", badge.BadgeId); foreach (string door in badge.Doors) { tableBody = tableBody + door + " "; } Console.WriteLine(tableBody); Console.WriteLine(); } }
public void GetBadgeDictionary_ShouldNotBeNull() { Assert.IsNotNull(_repo.GetBadgeDictionary()); }