Пример #1
0
        public void Replay()
        {
            var replay       = Random.StdGen.NewStdGen(395461793, 1);
            var config       = Config.VerboseThrowOnFailure.WithReplay(replay).WithName("ReplayConfig");
            var property     = IntBoolProperty.FromConverter(_ => true);
            var intsFromRun1 = CheckIntBoolProperty(config, property);
            var intsFromRun2 = CheckIntBoolProperty(config, property);

            Assert.That(intsFromRun1, Is.EqualTo(intsFromRun2));
        }
Пример #2
0
        private static IEnumerable <int> CheckIntBoolProperty(Config config, IntBoolProperty property)
        {
            var ints = new List <int>();

            Check.One(config, IntBoolProperty.FromConverter(i =>
            {
                ints.Add(i);
                return(property.Invoke(i));
            }));

            return(ints);
        }