Ejemplo n.º 1
0
        public void SiteCollectionWebSettingsTest()
        {
            using (var cc = TestCommon.CreateClientContext(centralSiteCollectionUrl))
            {
                // Add supporting files
                TestProvisioningTemplate(cc, "websettings_files.xml", Handlers.Files);

                var result = TestProvisioningTemplate(cc, "websettings_add.xml", Handlers.WebSettings);
                WebSettingsValidator wv = new WebSettingsValidator(cc);
                Assert.IsTrue(wv.Validate(result.SourceTemplate.WebSettings, result.TargetTemplate.WebSettings, result.TargetTokenParser));
            }
        }
Ejemplo n.º 2
0
        internal void WebWebSettings(string siteCollectionUrl, string url)
        {
            using (var cc = TestCommon.CreateClientContext(siteCollectionUrl))
            {
                // Add supporting files
                TestProvisioningTemplate(cc, "websettings_files.xml", Handlers.Files);
            }

            using (var cc = TestCommon.CreateClientContext(url))
            {
                var result = TestProvisioningTemplate(cc, "websettings_add.xml", Handlers.WebSettings);
                WebSettingsValidator wv = new WebSettingsValidator(cc);
                Assert.IsTrue(wv.Validate(result.SourceTemplate.WebSettings, result.TargetTemplate.WebSettings, result.TargetTokenParser));
            }
        }