Exemplo n.º 1
0
        public void CreateAttribute_using_late_bound_instancing_has_name()
        {
            var fac = new DomNodeFactory(
                new FDomNodeTypeProvider((name) => typeof(PAttributeWithName))
                );

            Assert.IsInstanceOf <PAttributeWithName>(fac.CreateAttribute("expected"));
            Assert.Equal("expected", fac.CreateAttribute("expected").LocalName);
        }
Exemplo n.º 2
0
        public void CreateAttribute_using_late_bound_instancing()
        {
            var fac = new DomNodeFactory(
                new FDomNodeTypeProvider((name) => typeof(PAttribute))
                );

            Assert.IsInstanceOf <PAttribute>(fac.CreateAttribute("myname"));
        }