diff --git a/Octokit.Tests/Clients/IssueTimelineClientTests.cs b/Octokit.Tests/Clients/IssueTimelineClientTests.cs index d041406a01..d877843647 100644 --- a/Octokit.Tests/Clients/IssueTimelineClientTests.cs +++ b/Octokit.Tests/Clients/IssueTimelineClientTests.cs @@ -31,7 +31,7 @@ public async Task RequestsTheCorrectUrl() connection.Received().GetAll( Arg.Is(u => u.ToString() == "repos/fake/repo/issues/42/timeline"), Arg.Any>(), - "application/vnd.github.mockingbird-preview,application/vnd.github.starfox-preview", + "application/vnd.github.mockingbird-preview+json,application/vnd.github.starfox-preview", Arg.Any()); } @@ -46,7 +46,7 @@ public async Task RequestsTheCorrectUrlWithApiOptions() connection.Received().GetAll( Arg.Is(u => u.ToString() == "repos/fake/repo/issues/42/timeline"), Arg.Any>(), - "application/vnd.github.mockingbird-preview,application/vnd.github.starfox-preview", + "application/vnd.github.mockingbird-preview+json,application/vnd.github.starfox-preview", Arg.Is(ao => ao.PageSize == 30)); } @@ -61,7 +61,7 @@ public async Task RequestsTheCorrectUrlWithRepositoryId() connection.Received().GetAll( Arg.Is(u => u.ToString() == "repositories/1/issues/42/timeline"), Arg.Any>(), - "application/vnd.github.mockingbird-preview,application/vnd.github.starfox-preview", + "application/vnd.github.mockingbird-preview+json,application/vnd.github.starfox-preview", Arg.Any()); } @@ -76,7 +76,7 @@ public async Task RequestsTheCorrectUrlWithRepositoryIdAndApiOptions() connection.Received().GetAll( Arg.Is(u => u.ToString() == "repositories/1/issues/42/timeline"), Arg.Any>(), - "application/vnd.github.mockingbird-preview,application/vnd.github.starfox-preview", + "application/vnd.github.mockingbird-preview+json,application/vnd.github.starfox-preview", Arg.Is(ao => ao.PageSize == 30)); } diff --git a/Octokit.Tests/Reactive/ObservableIssueTimelineClientTests.cs b/Octokit.Tests/Reactive/ObservableIssueTimelineClientTests.cs index dcc02ca275..836d9638d5 100644 --- a/Octokit.Tests/Reactive/ObservableIssueTimelineClientTests.cs +++ b/Octokit.Tests/Reactive/ObservableIssueTimelineClientTests.cs @@ -37,7 +37,7 @@ public async Task RequestsCorrectUrl() { ApiInfo = new ApiInfo(new Dictionary(), new List(), new List(), "etag", new RateLimit()), }, result); - gitHubClient.Connection.Get>(Args.Uri, Args.EmptyDictionary, "application/vnd.github.mockingbird-preview") + gitHubClient.Connection.Get>(Args.Uri, Args.EmptyDictionary, "application/vnd.github.mockingbird-preview+json") .Returns(Task.FromResult(response)); var timelineEvents = await client.GetAllForIssue("fake", "repo", 42).ToList(); @@ -45,7 +45,7 @@ public async Task RequestsCorrectUrl() connection.Received().Get>( Arg.Is(u => u.ToString() == "repos/fake/repo/issues/42/timeline"), Arg.Any>(), - "application/vnd.github.mockingbird-preview"); + "application/vnd.github.mockingbird-preview+json"); Assert.Equal(1, timelineEvents.Count); } @@ -63,7 +63,7 @@ public async Task RequestsCorrectUrlWithApiOptions() { ApiInfo = new ApiInfo(new Dictionary(), new List(), new List(), "etag", new RateLimit()), }, result); - gitHubClient.Connection.Get>(Args.Uri, Arg.Is>(d => d.Count == 1), "application/vnd.github.mockingbird-preview") + gitHubClient.Connection.Get>(Args.Uri, Arg.Is>(d => d.Count == 1), "application/vnd.github.mockingbird-preview+json") .Returns(Task.FromResult(response)); var timelineEvents = await client.GetAllForIssue("fake", "repo", 42, new ApiOptions { PageSize = 30 }).ToList(); @@ -71,7 +71,7 @@ public async Task RequestsCorrectUrlWithApiOptions() connection.Received().Get>( Arg.Is(u => u.ToString() == "repos/fake/repo/issues/42/timeline"), Arg.Is>(d => d.Count == 1 && d["per_page"] == "30"), - "application/vnd.github.mockingbird-preview"); + "application/vnd.github.mockingbird-preview+json"); Assert.Equal(1, timelineEvents.Count); } @@ -88,7 +88,7 @@ public async Task RequestCorrectUrlWithRepositoryId() { ApiInfo = new ApiInfo(new Dictionary(), new List(), new List(), "etag", new RateLimit()), }, result); - githubClient.Connection.Get>(Args.Uri, Args.EmptyDictionary, "application/vnd.github.mockingbird-preview") + githubClient.Connection.Get>(Args.Uri, Args.EmptyDictionary, "application/vnd.github.mockingbird-preview+json") .Returns(Task.FromResult(response)); var timelineEvents = await client.GetAllForIssue(1, 42).ToList(); @@ -96,7 +96,7 @@ public async Task RequestCorrectUrlWithRepositoryId() connection.Received().Get>( Arg.Is(u => u.ToString() == "repositories/1/issues/42/timeline"), Arg.Any>(), - "application/vnd.github.mockingbird-preview"); + "application/vnd.github.mockingbird-preview+json"); Assert.Equal(1, timelineEvents.Count); } @@ -113,7 +113,7 @@ public async Task RequestCorrectUrlWithRepositoryIdAndApiOptions() { ApiInfo = new ApiInfo(new Dictionary(), new List(), new List(), "etag", new RateLimit()), }, result); - githubClient.Connection.Get>(Args.Uri, Arg.Is>(d => d.Count == 1), "application/vnd.github.mockingbird-preview") + githubClient.Connection.Get>(Args.Uri, Arg.Is>(d => d.Count == 1), "application/vnd.github.mockingbird-preview+json") .Returns(Task.FromResult(response)); var timelineEvents = await client.GetAllForIssue(1, 42, new ApiOptions { PageSize = 30 }).ToList(); @@ -121,7 +121,7 @@ public async Task RequestCorrectUrlWithRepositoryIdAndApiOptions() connection.Received().Get>( Arg.Is(u => u.ToString() == "repositories/1/issues/42/timeline"), Arg.Is>(d => d.Count == 1 && d["per_page"] == "30"), - "application/vnd.github.mockingbird-preview"); + "application/vnd.github.mockingbird-preview+json"); Assert.Equal(1, timelineEvents.Count); }