mirror of https://github.com/abpframework/abp
				
				
				
			
			You can not select more than 25 topics
			Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
		
		
		
		
		
			
		
			
				
					
					
						
							50 lines
						
					
					
						
							1.6 KiB
						
					
					
				
			
		
		
	
	
							50 lines
						
					
					
						
							1.6 KiB
						
					
					
				| using Microsoft.Extensions.DependencyInjection;
 | |
| using Volo.Abp.AspNetCore.Mvc;
 | |
| using Volo.Abp.Http.Client;
 | |
| using Volo.Abp.Http.DynamicProxying;
 | |
| using Volo.Abp.Http.Localization;
 | |
| using Volo.Abp.Localization;
 | |
| using Volo.Abp.Localization.ExceptionHandling;
 | |
| using Volo.Abp.Modularity;
 | |
| using Volo.Abp.TestApp;
 | |
| using Volo.Abp.VirtualFileSystem;
 | |
| 
 | |
| namespace Volo.Abp.Http
 | |
| {
 | |
|     [DependsOn(
 | |
|         typeof(AbpHttpClientModule),
 | |
|         typeof(AbpAspNetCoreMvcTestModule)
 | |
|         )]
 | |
|     public class AbpHttpClientTestModule : AbpModule
 | |
|     {
 | |
|         public override void ConfigureServices(ServiceConfigurationContext context)
 | |
|         {
 | |
|             context.Services.AddHttpClientProxies(typeof(TestAppModule).Assembly);
 | |
|             context.Services.AddHttpClientProxy<IRegularTestController>();
 | |
| 
 | |
|             Configure<AbpRemoteServiceOptions>(options =>
 | |
|             {
 | |
|                 options.RemoteServices.Default = new RemoteServiceConfiguration("/");
 | |
|             });
 | |
| 
 | |
| 
 | |
|             Configure<AbpVirtualFileSystemOptions>(options =>
 | |
|             {
 | |
|                 options.FileSets.AddEmbedded<AbpHttpClientTestModule>();
 | |
|             });
 | |
| 
 | |
|             Configure<AbpLocalizationOptions>(options =>
 | |
|             {
 | |
|                 options.Resources
 | |
|                     .Add<HttpClientTestResource>("en")
 | |
|                     .AddVirtualJson("/Volo/Abp/Http/Localization");
 | |
|             });
 | |
| 
 | |
|             Configure<AbpExceptionLocalizationOptions>(options =>
 | |
|             {
 | |
|                 options.MapCodeNamespace("Volo.Abp.Http.DynamicProxying", typeof(HttpClientTestResource));
 | |
|             });
 | |
|         }
 | |
|     }
 | |
| }
 |