public FeatsGenerator(IRacialFeatsGenerator racialFeatsGenerator, IClassFeatsGenerator classFeatsGenerator, IAdditionalFeatsGenerator additionalFeatsGenerator, ICollectionsSelector collectionsSelector) { this.racialFeatsGenerator = racialFeatsGenerator; this.classFeatsGenerator = classFeatsGenerator; this.additionalFeatsGenerator = additionalFeatsGenerator; this.collectionsSelector = collectionsSelector; }
public void Setup() { mockFeatsSelector = new Mock<IFeatsSelector>(); mockFeatFocusGenerator = new Mock<IFeatFocusGenerator>(); mockCollectionsSelector = new Mock<ICollectionsSelector>(); classFeatsGenerator = new ClassFeatsGenerator(mockFeatsSelector.Object, mockFeatFocusGenerator.Object, mockCollectionsSelector.Object); characterClass = new CharacterClass(); stats = new Dictionary<string, Stat>(); stats[StatConstants.Intelligence] = new Stat(StatConstants.Intelligence); classFeatSelections = new Dictionary<string, List<CharacterClassFeatSelection>>(); racialFeats = new List<Feat>(); skills = new Dictionary<string, Skill>(); race = new Race(); mockFeatsSelector.Setup(s => s.SelectClass(It.IsAny<string>())).Returns(Enumerable.Empty<CharacterClassFeatSelection>()); mockCollectionsSelector.Setup(s => s.SelectRandomFrom(It.IsAny<IEnumerable<Feat>>())).Returns((IEnumerable<Feat> c) => c.First()); characterClass.Name = "class name"; characterClass.Level = 1; }