public void CanSerializeActorRef()
        {
            var message = new SomeMessage
            {
                ActorRef = TestActor,
            };

            var serializer   = Sys.Serialization.FindSerializerFor(message);
            var serialized   = serializer.ToBinary(message);
            var deserialized = (SomeMessage)serializer.FromBinary(serialized, typeof(SomeMessage));

            Assert.Same(TestActor, deserialized.ActorRef);
        }
        public void CanSerializeFutureActorRef()
        {
            Sys.EventStream.Subscribe(TestActor, typeof(object));
            var empty = Sys.ActorOf <EmptyActor>();

            empty.Ask("hello");
            var f = ExpectMsg <FutureActorRef>();


            var message = new SomeMessage
            {
                ActorRef = f,
            };

            var serializer   = Sys.Serialization.FindSerializerFor(message);
            var serialized   = serializer.ToBinary(message);
            var deserialized = (SomeMessage)serializer.FromBinary(serialized, typeof(SomeMessage));

            Assert.Same(f, deserialized.ActorRef);
        }