コード例 #1
0
 public void ParserActorTest()
 {
     TestLauncherActor.Test(() =>
     {
         ActorServer.Start(ActorConfigManager.CastForTest());
         var parserTest = new ParserTest();
         var receiver   = new TestReceiver();
         parserTest.SendMessage((IActor)receiver);
         var future = receiver.GetResult().Result();
         Assert.IsTrue(future.Any());
         Assert.IsTrue(future.Contains("Max"));
     });
 }
コード例 #2
0
 public void ParserActorTest()
 {
     TestLauncherActor.Test(() =>
     {
         ConfigurationManager.AppSettings["ListenerService"]  = "MemoryListenerService";
         ConfigurationManager.AppSettings["SerializeService"] = "NetDataContractSerializeService";
         ActorServer.Start("localhost", 80, new HostRelayActor());
         var parserTest = new ParserTest();
         var receiver   = new TestReceiver();
         parserTest.SendMessage((IActor)receiver);
         var future = receiver.GetResult().Result();
         Assert.IsTrue(future.Any());
         Assert.IsTrue(future.Contains("Max"));
     });
 }