예제 #1
0
        public void Seed_WithTags_Ok()
        {
            OrthographyLayerFragmentSeeder seeder = new OrthographyLayerFragmentSeeder();

            seeder.SetSeedOptions(_seedOptions);
            seeder.Configure(new OrthographyLayerFragmentSeederOptions
            {
                Tags = new[]
                {
                    "alpha",
                    "beta",
                    "gamma"
                }
            });

            ITextLayerFragment fragment = seeder.GetFragment(_item, "1.1", "alpha");

            Assert.NotNull(fragment);

            OrthographyLayerFragment fr = fragment as OrthographyLayerFragment;

            Assert.NotNull(fr);

            Assert.Equal("1.1", fr.Location);
            Assert.NotNull(fr.Standard);
            Assert.Single(fr.Operations);
            MspOperation op = MspOperation.Parse(fr.Operations[0]);

            Assert.NotNull(op.Tag);
        }
예제 #2
0
        public void Seed_WithoutTags_Ok()
        {
            OrthographyLayerFragmentSeeder seeder = new OrthographyLayerFragmentSeeder();

            ITextLayerFragment fragment = seeder.GetFragment(_item, "1.1", "alpha");

            Assert.NotNull(fragment);

            OrthographyLayerFragment fr = fragment as OrthographyLayerFragment;

            Assert.NotNull(fr);

            Assert.Equal("1.1", fr.Location);
            Assert.NotNull(fr.Standard);
            Assert.Single(fr.Operations);
            MspOperation op = MspOperation.Parse(fr.Operations[0]);

            Assert.Null(op.Tag);
        }
예제 #3
0
        public void GetFragmentType_Ok()
        {
            OrthographyLayerFragmentSeeder seeder = new OrthographyLayerFragmentSeeder();

            Assert.Equal(typeof(OrthographyLayerFragment), seeder.GetFragmentType());
        }