private static AvailableWitnessesPart GetPart()
        {
            AvailableWitnessesPartSeeder seeder =
                new AvailableWitnessesPartSeeder();
            IItem item = new Item
            {
                FacetId     = "default",
                CreatorId   = "zeus",
                UserId      = "zeus",
                Description = "Test item",
                Title       = "Test Item",
                SortKey     = ""
            };

            return((AvailableWitnessesPart)seeder.GetPart(item, null, null));
        }
Beispiel #2
0
        public void Seed_Ok()
        {
            AvailableWitnessesPartSeeder seeder =
                new AvailableWitnessesPartSeeder();

            seeder.SetSeedOptions(_seedOptions);

            IPart part = seeder.GetPart(_item, null, _factory);

            Assert.NotNull(part);

            AvailableWitnessesPart p = part as AvailableWitnessesPart;

            Assert.NotNull(p);

            TestHelper.AssertPartMetadata(p);

            Assert.NotEmpty(p.Witnesses);
        }