예제 #1
0
        public void String_Tests()
        {
            var protocol  = new StringProtocol();
            var pubconfig = protocol.Encode("this is a test");
            var props     = new BasicProperties();
            var decoded   = protocol.Decode(pubconfig.Body, string.Empty, string.Empty, props);

            Assert.AreEqual("this is a test", decoded);

            pubconfig = protocol.Encode("");
            decoded   = protocol.Decode(pubconfig.Body, string.Empty, string.Empty, props);
            Assert.AreEqual("", decoded);
        }
예제 #2
0
 public void NullString()
 {
     var protocol  = new StringProtocol();
     var pubconfig = protocol.Encode(null);
 }