Пример #1
0
        public void ConfigureWithXmlModulePropertySetTest()
        {
            DependencyInjectionContainer container = new DependencyInjectionContainer();

            container.ConfigureWithXml();

            int intProperty = (int)container.Locate("IntProperty");

            Assert.Equal(5, intProperty);
        }
Пример #2
0
        public void ConfigureWithXmlModuleTest()
        {
            DependencyInjectionContainer container = new DependencyInjectionContainer();

            container.ConfigureWithXml();

            IBasicService basicService = container.Locate<IBasicService>();

            Assert.NotNull(basicService);
        }
Пример #3
0
        public void ConfigureWithXmlExportTest()
        {
            DependencyInjectionContainer container = new DependencyInjectionContainer();

            container.ConfigureWithXml();

            IConstructorImportService importService = container.Locate<IConstructorImportService>();

            Assert.NotNull(importService);
        }
Пример #4
0
        public void ConfigureWithXmlThirdSectionWithShortNames()
        {
            DependencyInjectionContainer container = new DependencyInjectionContainer();

            container.ConfigureWithXml("thirdGrace");

            IConstructorImportService importService = container.Locate<IConstructorImportService>();

            Assert.NotNull(importService);

            Assert.Equal(5, container.Locate("IntProperty"));
        }