コード例 #1
0
        public void enumeration_contains_ReplyTo_when_Replyto_set_in_message_extension()
        {
            var msg     = CreateMessageWithReplyToExtension();
            var headers = new ReadOnlyMsmqMessageHeaders(msg);
            var found   = headers.SingleOrDefault(pair => pair.Key == nameof(headers.ReplyTo));

            Assert.IsNotNull(found);
            Assert.AreEqual(new Uri("tibrv://localhost/ReadOnlyMsmq/MessageTests"), found.Value);
        }
コード例 #2
0
        public void enumeration_contains_ReplyTo_when_ResponseQueue_set_on_message()
        {
            var msg     = CreateMessageWithResponseQueue();
            var headers = new ReadOnlyMsmqMessageHeaders(msg);
            var found   = headers.SingleOrDefault(pair => pair.Key == nameof(headers.ReplyTo));

            Assert.IsNotNull(found);
            Assert.AreEqual(new Uri($"msmq+os://{Environment.MachineName}/private$/ReadOnlyMsmqMessageTests"), found.Value);
        }