move to from olive to mcs
[mono.git] / mcs / class / System.ServiceModel / Test / FeatureBased / Features.Serialization / UntypedMessageTest.cs
1 using System;
2 using System.Collections.Generic;
3 using System.Text;
4 using NUnit.Framework;
5 using Proxy.MonoTests.Features.Client;
6 using System.ServiceModel;
7 using System.ServiceModel.Channels;
8
9 namespace MonoTests.Features.Serialization
10 {
11         [TestFixture]
12         [Category ("NotWorking")] // Message version mismatch. Expected Soap11, Received Soap12
13     public class UntypedMessageTest : TestFixtureBase<UntypedMessageTesterContractClient, MonoTests.Features.Contracts.UntypedMessageTester, MonoTests.Features.Contracts.IUntypedMessageTesterContract>
14         {
15                 [Test]
16                 public void TestUntypedMessage ()
17                 {
18                         String action = "http://localhost/UntypedMessageTester/Message_RequestAction";
19                         using (new OperationContextScope (ClientProxy.InnerChannel)) {
20                                 // Call the Sum service operation.
21                                 string [] strings = { "a", "b", "c" };
22                                 Message request = Message.CreateMessage (OperationContext.Current.OutgoingMessageHeaders.MessageVersion, action, strings);
23                                 Message reply = Client.ConcatStrings (request);
24                                 string r = reply.GetBody<string> ();
25
26                                 Assert.AreEqual (r, "abc", "#1");
27                         }
28
29
30                 }
31         }
32 }