Exemple #1
0
        public void ValidateDoesNotThrow()
        {
            var iha = new HttpAdapter.Inbound(
                a => {
                a.LoopBack                = false;
                a.ResponseContentType     = MediaTypeNames.Application.Pdf;
                a.ReturnCorrelationHandle = true;
            });

            Assert.That(() => ((ISupportValidation)iha).Validate(), Throws.Nothing);
        }
        public void ValidateDoesNotThrow()
        {
            Skip.IfNot(BizTalkServerGroup.IsConfigured);

            var iha = new HttpAdapter.Inbound(
                a => {
                a.LoopBack                = false;
                a.ResponseContentType     = MediaTypeNames.Application.Pdf;
                a.ReturnCorrelationHandle = true;
            });

            Invoking(() => ((ISupportValidation)iha).Validate()).Should().NotThrow();
        }
        public void SerializeToXml()
        {
            Skip.IfNot(BizTalkServerGroup.IsConfigured);

            var iha = new HttpAdapter.Inbound(
                a => {
                a.LoopBack                = false;
                a.ResponseContentType     = MediaTypeNames.Application.Pdf;
                a.ReturnCorrelationHandle = true;
            });
            var xml = iha.GetAdapterBindingInfoSerializer().Serialize();

            xml.Should().Be(
                "<CustomProps>" +
                "<LoopBack vt=\"11\">0</LoopBack>" +
                "<ResponseContentType vt=\"8\">application/pdf</ResponseContentType>" +
                "<ReturnCorrelationHandle vt=\"11\">-1</ReturnCorrelationHandle>" +
                "<SuspendFailedRequests vt=\"11\">-1</SuspendFailedRequests>" +
                "<UseSSO vt=\"11\">0</UseSSO>" +
                "</CustomProps>");
        }
Exemple #4
0
        public void SerializeToXml()
        {
            var iha = new HttpAdapter.Inbound(
                a => {
                a.LoopBack                = false;
                a.ResponseContentType     = MediaTypeNames.Application.Pdf;
                a.ReturnCorrelationHandle = true;
            });
            var xml = ((IAdapterBindingSerializerFactory)iha).GetAdapterBindingSerializer().Serialize();

            Assert.That(
                xml,
                Is.EqualTo(
                    "<CustomProps>" +
                    "<LoopBack vt=\"11\">0</LoopBack>" +
                    "<ResponseContentType vt=\"8\">application/pdf</ResponseContentType>" +
                    "<ReturnCorrelationHandle vt=\"11\">-1</ReturnCorrelationHandle>" +
                    "<SuspendFailedRequests vt=\"11\">-1</SuspendFailedRequests>" +
                    "<UseSSO vt=\"11\">0</UseSSO>" +
                    "</CustomProps>"));
        }