Example #1
0
        public void add_selection_values()
        {
            var fixture = new Fixture();

            fixture.AddSelectionValues("States", "TX", "AR", "MO");
            fixture.AddSelectionValues("Animals", "Lions", "Tigers", "Pumas");

            fixture.Lists["States"].Options.Select(x => x.value)
                .ShouldHaveTheSameElementsAs("TX", "AR", "MO");

            fixture.Lists["Animals"].Options.Select(x => x.value)
                .ShouldHaveTheSameElementsAs("Lions", "Tigers", "Pumas");
        }
        public void add_selection_values()
        {
            var fixture = new Fixture();

            fixture.AddSelectionValues("States", "TX", "AR", "MO");
            fixture.AddSelectionValues("Animals", "Lions", "Tigers", "Pumas");

            fixture.GetSelectionValues("States")
            .ShouldHaveTheSameElementsAs("TX", "AR", "MO");

            fixture.GetSelectionValues("Animals")
            .ShouldHaveTheSameElementsAs("Lions", "Tigers", "Pumas");
        }
        public void SetUp()
        {
            fixture = new Fixture();
            cell    = Cell.For <string>("name");

            fixture.AddSelectionValues("names", "Jeremy", "Max", "Monte");
        }
        public void SetUp()
        {
            fixture = new Fixture();
            cell = Cell.For<string>("name");

            fixture.AddSelectionValues("names", "Jeremy", "Max", "Monte");
        }
        public void list_on_fixture_has_precedence()
        {
            var handling = CellHandling.Basic();

            handling.AddSystemLevelList("States", new[] { "TX", "MO", "AR" });

            var fixture = new Fixture();

            fixture.AddSelectionValues("States", "NY", "CT");

            var property = ReflectionHelper.GetProperty <CellTarget>(x => x.State);
            var cell     = Cell.For(handling, property, fixture);

            cell.options.Select(x => x.value)
            .ShouldHaveTheSameElementsAs("NY", "CT");
        }
Example #6
0
        public void list_on_fixture_has_precedence()
        {
            var handling = CellHandling.Basic();
            handling.AddSystemLevelList("States", new[] { "TX", "MO", "AR" });

            var fixture = new Fixture();
            fixture.AddSelectionValues("States", "NY", "CT");

            var property = ReflectionHelper.GetProperty<CellTarget>(x => x.State);
            var cell = Cell.For(handling, property, fixture);
            cell.options.Select(x => x.value)
                .ShouldHaveTheSameElementsAs("NY", "CT");
        }