Пример #1
0
        private static async Task <Configuration> createAndGetConfig()
        {
            ConfigurationInitializer configurationInitializer = new ConfigurationInitializer();

            Configuration configuration = await configurationInitializer.CreateIfNecessaryAndGetConfig();

            configuration.SecretPath = Directory.GetCurrentDirectory() + configuration.SecretPath;
            return(configuration);
        }
Пример #2
0
        private static CompilationResult ExportConfiguration(CompilerOptions options)
        {
            var assembly = Assembly.LoadFile(options.WebSiteAssembly);
            var config   = ConfigurationInitializer.InitDotVVM(assembly, options.WebSitePath, null, collection => { });

            return(new CompilationResult()
            {
                Configuration = config
            });
        }
        public EventfulHttpClientTests()
        {
            _httpClient = new HttpClient();

            var configuration = ConfigurationInitializer.InitConfiguration();

            _settings = new EventfulSettings
            {
                BaseUrl = configuration["EventfulSettings:BaseUrl"],
                ApiKey  = configuration["EventfulSettings:ApiKey"]
            };
        }
Пример #4
0
 private DotvvmConfiguration GetCachedConfiguration(Assembly assembly, string webSitePath, Action <IServiceCollection> additionalServices)
 {
     return(cachedConfig.GetOrAdd($"{assembly.GetName().Name}|{webSitePath}",
                                  key => ConfigurationInitializer.InitDotVVM(assembly, webSitePath, this, additionalServices)));
 }