Skip to content

Commit 5b44b62

Browse files
Merge pull request #356 from microsoftgraph/januaryrelease
January Release
2 parents a36579c + 470ef44 commit 5b44b62

File tree

4 files changed

+16
-11
lines changed

4 files changed

+16
-11
lines changed

src/Microsoft.Graph.Core/Microsoft.Graph.Core.csproj

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,12 @@
1313
<PackageId>Microsoft.Graph.Core</PackageId>
1414
<PackageTags>Microsoft Office365;Graph;GraphServiceClient;Outlook;OneDrive;AzureAD;GraphAPI;Productivity;SharePoint;Intune;SDK</PackageTags>
1515
<PackageReleaseNotes>
16-
January 2019 Release Summary (version 1.13.0-preview.2)
16+
January 2019 Release Summary (version 1.13.0)
1717

1818
- Authentication handler added.
1919
- Removed Newtonsoft.Json package reference upper bound limitation.
20+
- Makes GraphClientFactory internal.
21+
- HttpProvider uses GraphClientFactory.
2022
</PackageReleaseNotes>
2123
<PackageProjectUrl>https://developer.microsoft.com/graph</PackageProjectUrl>
2224
<PackageLicenseUrl>http://aka.ms/devservicesagreement</PackageLicenseUrl>
@@ -36,7 +38,7 @@ January 2019 Release Summary (version 1.13.0-preview.2)
3638
<DelaySign>false</DelaySign>
3739
<AssemblyOriginatorKeyFile>35MSSharedLib1024.snk</AssemblyOriginatorKeyFile>
3840
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
39-
<Version>1.13.0-preview.2</Version>
41+
<Version>1.13.0</Version>
4042
</PropertyGroup>
4143
<PropertyGroup Condition="'$(Configuration)|$(TargetFramework)|$(Platform)'=='Debug|netstandard1.1|AnyCPU'">
4244
<DocumentationFile>bin\Release\netstandard1.1\Microsoft.Graph.Core.xml</DocumentationFile>

src/Microsoft.Graph/Microsoft.Graph.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
<PackageId>Microsoft.Graph</PackageId>
1414
<PackageTags>Microsoft Office365;Graph;GraphServiceClient;Outlook;OneDrive;AzureAD;GraphAPI;Productivity;SharePoint;Intune;SDK</PackageTags>
1515
<PackageReleaseNotes>
16-
January 2019 Release Summary (version 1.13.0-preview.2)
16+
January 2019 Release Summary (version 1.13.0)
1717

1818
New functionality
1919
- Added new Teams API functionality.
@@ -45,7 +45,7 @@ Updated functionality
4545
<DelaySign>false</DelaySign>
4646
<AssemblyOriginatorKeyFile>35MSSharedLib1024.snk</AssemblyOriginatorKeyFile>
4747
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
48-
<Version>1.13.0-preview.2</Version>
48+
<Version>1.13.0</Version>
4949
</PropertyGroup>
5050
<PropertyGroup Condition="'$(Configuration)|$(TargetFramework)|$(Platform)'=='Debug|netstandard1.1|AnyCPU'">
5151
<DocumentationFile>bin\Release\Microsoft.Graph.xml</DocumentationFile>

tests/Microsoft.Graph.DotnetCore.Core.Test/Mocks/MockRedirctHandler.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,13 +23,13 @@ protected async override Task<HttpResponseMessage> SendAsync(HttpRequestMessage
2323
{
2424
_response1Sent = true;
2525
_response1.RequestMessage = request;
26-
return _response1;
26+
return await Task.FromResult(_response1);
2727
}
2828
else
2929
{
3030
_response1Sent = false;
3131
_response2.RequestMessage = request;
32-
return _response2;
32+
return await Task.FromResult(_response2);
3333
}
3434
}
3535

tests/Microsoft.Graph.DotnetCore.Core.Test/Requests/GraphClientFactoryTests.cs

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ public class GraphClientFactoryTests : IDisposable
2525
public GraphClientFactoryTests()
2626
{
2727
this.testHttpMessageHandler = new MockRedirectHandler();
28-
handlers = handlers = new DelegatingHandler[3];
28+
handlers = new DelegatingHandler[3];
2929
handlers[0] = new RetryHandler();
3030
handlers[1] = new RedirectHandler();
3131
handlers[2] = new AuthenticationHandler(authenticationProvider.Object);
@@ -37,24 +37,27 @@ public void Dispose()
3737
this.testHttpMessageHandler.Dispose();
3838
}
3939

40+
// Note:
41+
// 1. Xunit's IsType doesn't consider inheritance behind the classes.
42+
// 2. We can't control the order of execution for the tests
43+
// and 'GraphClientFactory.DefaultHttpHandler' can easily be modified
44+
// by other tests since it's a static delegate.
4045
[Fact]
4146
public void CreatePipelineWithoutHttpMessageHandlerInput()
4247
{
4348
using (RetryHandler retryHandler = (RetryHandler)GraphClientFactory.CreatePipeline(handlers))
4449
using (RedirectHandler redirectHandler = (RedirectHandler)retryHandler.InnerHandler)
4550
using (AuthenticationHandler authenticationHandler = (AuthenticationHandler)redirectHandler.InnerHandler)
46-
using (HttpClientHandler innerMost = (HttpClientHandler)authenticationHandler.InnerHandler)
51+
using (HttpMessageHandler innerMost = authenticationHandler.InnerHandler)
4752
{
48-
System.Diagnostics.Debug.WriteLine("InvalidCast: " + authenticationHandler.InnerHandler.GetType().ToString());
49-
5053
Assert.NotNull(retryHandler);
5154
Assert.NotNull(redirectHandler);
5255
Assert.NotNull(authenticationHandler);
5356
Assert.NotNull(innerMost);
5457
Assert.IsType(typeof(RetryHandler), retryHandler);
5558
Assert.IsType(typeof(RedirectHandler), redirectHandler);
5659
Assert.IsType(typeof(AuthenticationHandler), authenticationHandler);
57-
Assert.IsType(typeof(HttpClientHandler), innerMost);
60+
Assert.True(innerMost is HttpMessageHandler);
5861
}
5962

6063
}

0 commit comments

Comments
 (0)