Beispiel #1
0
        public void GetParameterSets_ReturnsCorrectNumberOfSets(int numberOfSets)
        {
            var paramProvider = new ParameterProvider();
            var builders      = new IParameterValueBuilder[] { new FakeParameterValueBuilder("ParamOne", 1) };

            var sets = paramProvider.GetParameterSets(builders, numberOfSets);

            Assert.AreEqual(numberOfSets, sets.Count());
        }
Beispiel #2
0
        public void GetParameterSets_ReturnsSetWithParameterFromEachBuilder()
        {
            var paramProvider = new ParameterProvider();
            var builders      = new IParameterValueBuilder[]
            {
                new FakeParameterValueBuilder("ParamOne", 1),
                new FakeParameterValueBuilder("ParamTwo", 2)
            };

            var set = paramProvider.GetParameterSets(builders, numberOfSets: 1).Single();

            var expected = new ParameterSet();

            expected.Add(new ParameterValue("ParamOne", 1));
            expected.Add(new ParameterValue("ParamTwo", 2));

            set.Parameters.Should().BeEquivalentTo(expected.Parameters);
        }