feat: Removing accept header previews (#2515)

This commit is contained in:
Chris Simpson
2022-08-01 15:37:23 +01:00
committed by GitHub
parent 840935a8d7
commit 2f7bd00dd6
138 changed files with 954 additions and 1659 deletions
+3 -2
View File
@@ -22,13 +22,14 @@ namespace Octokit.Tests.Http
var getUri = new Uri("anything", UriKind.Relative);
IApiResponse<object> response = new ApiResponse<object>(CreateResponse(HttpStatusCode.OK));
var connection = Substitute.For<IConnection>();
connection.Get<object>(Args.Uri, null, null).Returns(Task.FromResult(response));
connection.Get<object>(Args.Uri, null).Returns(Task.FromResult(response));
var apiConnection = new ApiConnection(connection);
var data = await apiConnection.Get<object>(getUri);
Assert.Same(response.Body, data);
connection.Received().GetResponse<object>(getUri);
var calls = connection.ReceivedCalls();
connection.Received().Get<object>(getUri, null, null);
}
[Fact]