Example #1
0
        public void Should_parse_all_rarities(IEnumerable<string> lines, ItemRarity itemRarity, ItemType expectedItemType)
        {
            itemRarityParser.Parse(Arg.Any<IEnumerable<string>>()).Returns(itemRarity);

            var target = new ItemTypeParser(wandDefinitions, itemRarityParser);

            target.Parse(lines).Should().Be(expectedItemType);
        }
Example #2
0
 public ItemParser()
 {
     itemRarityParser = new ItemRarityParser();
     itemTypeParser = new ItemTypeParser(new ItemDefinition[0], itemRarityParser);
     parsers = new IParser<Item, object>[]
     {
     };
 }