diff options
author | Andrew Arnott <andrewarnott@gmail.com> | 2013-03-22 06:22:36 -0700 |
---|---|---|
committer | Andrew Arnott <andrewarnott@gmail.com> | 2013-03-22 06:22:36 -0700 |
commit | 4c432c1278f301c3c80097866accca679e929fed (patch) | |
tree | d21dc94faeca5b600460abac10bd5080935cd12a /src/DotNetOpenAuth.Test/OAuth/ChannelElements/OAuthChannelTests.cs | |
parent | 579703ee02408e7d3cdd604aa263e95a6f1e49c3 (diff) | |
download | DotNetOpenAuth-4c432c1278f301c3c80097866accca679e929fed.zip DotNetOpenAuth-4c432c1278f301c3c80097866accca679e929fed.tar.gz DotNetOpenAuth-4c432c1278f301c3c80097866accca679e929fed.tar.bz2 |
Fixes remaining build breaks.
Diffstat (limited to 'src/DotNetOpenAuth.Test/OAuth/ChannelElements/OAuthChannelTests.cs')
-rw-r--r-- | src/DotNetOpenAuth.Test/OAuth/ChannelElements/OAuthChannelTests.cs | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/src/DotNetOpenAuth.Test/OAuth/ChannelElements/OAuthChannelTests.cs b/src/DotNetOpenAuth.Test/OAuth/ChannelElements/OAuthChannelTests.cs index a1db784..834aba2 100644 --- a/src/DotNetOpenAuth.Test/OAuth/ChannelElements/OAuthChannelTests.cs +++ b/src/DotNetOpenAuth.Test/OAuth/ChannelElements/OAuthChannelTests.cs @@ -301,17 +301,8 @@ namespace DotNetOpenAuth.Test.OAuth.ChannelElements { HttpMethods = scheme, }; - await RunAsync( - async (hostFactories, CancellationToken) => { - IProtocolMessage response = await this.channel.RequestAsync(request, CancellationToken.None); - Assert.IsNotNull(response); - Assert.IsInstanceOf<TestMessage>(response); - TestMessage responseMessage = (TestMessage)response; - Assert.AreEqual(request.Age, responseMessage.Age); - Assert.AreEqual(request.Name, responseMessage.Name); - Assert.AreEqual(request.Location, responseMessage.Location); - }, - Handle(request.Location).By(async (req, ct) => { + Handle(request.Location).By( + async (req, ct) => { Assert.IsNotNull(req); Assert.AreEqual(MessagingUtilities.GetHttpVerb(scheme), req.Method); var incomingMessage = (await this.channel.ReadFromRequestAsync(req, CancellationToken.None)) as TestMessage; @@ -330,7 +321,15 @@ namespace DotNetOpenAuth.Test.OAuth.ChannelElements { var rawResponse = new HttpResponseMessage(); rawResponse.Content = new StringContent(MessagingUtilities.CreateQueryString(responseFields)); return rawResponse; - })); + }); + + IProtocolMessage response = await this.channel.RequestAsync(request, CancellationToken.None); + Assert.IsNotNull(response); + Assert.IsInstanceOf<TestMessage>(response); + TestMessage responseMessage = (TestMessage)response; + Assert.AreEqual(request.Age, responseMessage.Age); + Assert.AreEqual(request.Name, responseMessage.Name); + Assert.AreEqual(request.Location, responseMessage.Location); } private async Task ParameterizedReceiveTestAsync(HttpDeliveryMethods scheme) { |