示例#1
0
        public void EncodeDecodeDiscoveryRequest()
        {
            var request = new DiscoveryRequest("SomeService");
            var encoded = DiscoveryMetadataHelper.Encode(request);
            var decoded = DiscoveryMetadataHelper.Decode(encoded);

            Assert.IsNotNull(decoded);
            Assert.AreEqual(request, decoded);
        }
示例#2
0
        public void RequestResponseMatch()
        {
            var req = new DiscoveryRequest("UltimaService");
            var rsp = new DiscoveryResponse("tcp://*****:*****@"\c");
            Assert.IsFalse(rsp.Matches(req));

            req = new DiscoveryRequest(@")");
            Assert.IsFalse(rsp.Matches(req));
        }