Esempio n. 1
0
        public void ConfigureServices(IServiceCollection services)
        {
            services.AddCors(options => {
                options.AddPolicy(
                    "AllowAny",
                    policy => {
                    policy.AllowAnyMethod();
                    policy.AllowAnyHeader();
                    policy.AllowAnyOrigin();
                });
            });

            services.AddJsonRpc();

            services.AddTransient(_ =>
                                  JsonRpcClient.Build <IBakery>(new Uri("http://localhost:53712/v1")));

            services.AddTransient(_ =>
                                  JsonRpcClient.Build <IButcher>(new Uri("http://localhost:53990/v2")));
        }
Esempio n. 2
0
 public override void TestInitialize()
 {
     burritoShop        = JsonRpcClient.Build <IBurritoShop>(new Uri("http://localhost:57982/v1"));
     burritoShopBatched = (IBatched <IBurritoShop>)burritoShop;
 }
Esempio n. 3
0
 public void TestInitialize()
 {
     butcherV10 = JsonRpcClient.Build <V10.IButcher>(new Uri("http://localhost:53990/v1"));
     butcherV11 = JsonRpcClient.Build <V11.IButcher>(new Uri("http://localhost:53990/v1"));
     butcherV2  = JsonRpcClient.Build <V2.IButcher>(new Uri("http://localhost:53990/v2"));
 }