示例#1
0
        public void WhenBuildingContext_EmbeddedResourcesCanBeFoundForConfiguredAssemblies()
        {
            _instance.Assemblies.Add(this.GetType().Assembly.GetName().Name);
            var fileFinder = ResourceFinderFactory.Null;
            var context    = _instance.BuildContext(ResourceMode.Debug, fileFinder, NullPreCompiledPersister.Instance);
            var resources  = context.Finder.FindResources(ResourceType.Stylesheet).ToList();

            Assert.IsNotNull(resources);
            Assert.IsTrue(resources.Count > 0, "Resource count should be greater than zero.");
        }
示例#2
0
        private void ConsolidateAll(AssmanConfiguration configSection)
        {
            var context  = configSection.BuildContext(Mode, usePreCompilationReportIfPresent: false);
            var compiler = context.GetCompiler();
            var report   = compiler.CompileAll(WriteCompiledResource);

            report.Version = this.Version ?? DateTime.Now.ToString("yyMMddHHmm");
            configSection.SavePreConsolidationReport(report);
        }