From 8ee07dd355444569518aaa7cd713140428ccfc1f Mon Sep 17 00:00:00 2001 From: Alexander Efremov Date: Mon, 13 Jun 2016 19:37:47 +0700 Subject: [PATCH 1/6] added new overloads modified XML docs --- .../Clients/IObservableEventsClient.cs | 48 ++++++++++++++ .../Clients/ObservableEventsClient.cs | 64 +++++++++++++++++++ Octokit/Clients/EventsClient.cs | 61 +++++++++++++++++- Octokit/Clients/IEventsClient.cs | 46 ++++++++++++- 4 files changed, 215 insertions(+), 4 deletions(-) diff --git a/Octokit.Reactive/Clients/IObservableEventsClient.cs b/Octokit.Reactive/Clients/IObservableEventsClient.cs index 803a23fc21..14b296e0bd 100644 --- a/Octokit.Reactive/Clients/IObservableEventsClient.cs +++ b/Octokit.Reactive/Clients/IObservableEventsClient.cs @@ -2,6 +2,12 @@ namespace Octokit.Reactive { + /// + /// A client for GitHub's Activity Events API. + /// + /// + /// See the Activity Events API documentation for more information + /// public interface IObservableEventsClient { /// @@ -35,6 +41,16 @@ public interface IObservableEventsClient /// All the s for the particular repository. IObservable GetAllForRepository(string owner, string name); + /// + /// Gets all the events for a given repository + /// + /// + /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository + /// + /// The ID of the repository + /// All the s for the particular repository. + IObservable GetAllForRepository(int repositoryId); + /// /// Gets all the events for a given repository /// @@ -47,6 +63,17 @@ public interface IObservableEventsClient /// All the s for the particular repository. IObservable GetAllForRepository(string owner, string name, ApiOptions options); + /// + /// Gets all the events for a given repository + /// + /// + /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository + /// + /// The ID of the repository + /// Options for changing the API response + /// All the s for the particular repository. + IObservable GetAllForRepository(int repositoryId, ApiOptions options); + /// /// Gets all the issue events for a given repository /// @@ -58,6 +85,16 @@ public interface IObservableEventsClient /// All the s for the particular repository. IObservable GetAllIssuesForRepository(string owner, string name); + /// + /// Gets all the issue events for a given repository + /// + /// + /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository + /// + /// The ID of the repository + /// All the s for the particular repository. + IObservable GetAllIssuesForRepository(int repositoryId); + /// /// Gets all the issue events for a given repository /// @@ -70,6 +107,17 @@ public interface IObservableEventsClient /// All the s for the particular repository. IObservable GetAllIssuesForRepository(string owner, string name, ApiOptions options); + /// + /// Gets all the issue events for a given repository + /// + /// + /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository + /// + /// The ID of the repository + /// Options for changing the API response + /// All the s for the particular repository. + IObservable GetAllIssuesForRepository(int repositoryId, ApiOptions options); + /// /// Gets all the events for a given repository network /// diff --git a/Octokit.Reactive/Clients/ObservableEventsClient.cs b/Octokit.Reactive/Clients/ObservableEventsClient.cs index 40eba047ff..318adce7df 100644 --- a/Octokit.Reactive/Clients/ObservableEventsClient.cs +++ b/Octokit.Reactive/Clients/ObservableEventsClient.cs @@ -3,6 +3,12 @@ namespace Octokit.Reactive { + /// + /// A client for GitHub's Activity Events API. + /// + /// + /// See the Activity Events API documentation for more information + /// public class ObservableEventsClient : IObservableEventsClient { readonly IConnection _connection; @@ -58,6 +64,19 @@ public IObservable GetAllForRepository(string owner, string name) return GetAllForRepository(owner, name, ApiOptions.None); } + /// + /// Gets all the events for a given repository + /// + /// + /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository + /// + /// The ID of the repository + /// All the s for the particular repository. + public IObservable GetAllForRepository(int repositoryId) + { + return GetAllForRepository(repositoryId, ApiOptions.None); + } + /// /// Gets all the events for a given repository /// @@ -77,6 +96,22 @@ public IObservable GetAllForRepository(string owner, string name, ApiO return _connection.GetAndFlattenAllPages(ApiUrls.Events(owner, name), options); } + /// + /// Gets all the events for a given repository + /// + /// + /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository + /// + /// The ID of the repository + /// Options for changing the API response + /// All the s for the particular repository. + public IObservable GetAllForRepository(int repositoryId, ApiOptions options) + { + Ensure.ArgumentNotNull(options, "options"); + + return _connection.GetAndFlattenAllPages(ApiUrls.Events(repositoryId), options); + } + /// /// Gets all the events for a given repository /// @@ -94,6 +129,19 @@ public IObservable GetAllIssuesForRepository(string owner, string name return GetAllIssuesForRepository(owner, name, ApiOptions.None); } + /// + /// Gets all the issue events for a given repository + /// + /// + /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository + /// + /// The ID of the repository + /// All the s for the particular repository. + public IObservable GetAllIssuesForRepository(int repositoryId) + { + return GetAllIssuesForRepository(repositoryId, ApiOptions.None); + } + /// /// Gets all the events for a given repository /// @@ -113,6 +161,22 @@ public IObservable GetAllIssuesForRepository(string owner, string name return _connection.GetAndFlattenAllPages(ApiUrls.IssuesEvents(owner, name), options); } + /// + /// Gets all the issue events for a given repository + /// + /// + /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository + /// + /// The ID of the repository + /// Options for changing the API response + /// All the s for the particular repository. + public IObservable GetAllIssuesForRepository(int repositoryId, ApiOptions options) + { + Ensure.ArgumentNotNull(options, "options"); + + return _connection.GetAndFlattenAllPages(ApiUrls.IssuesEvents(repositoryId), options); + } + /// /// Gets all the events for a given repository network /// diff --git a/Octokit/Clients/EventsClient.cs b/Octokit/Clients/EventsClient.cs index aecf303be9..d6c9147428 100644 --- a/Octokit/Clients/EventsClient.cs +++ b/Octokit/Clients/EventsClient.cs @@ -61,7 +61,20 @@ public Task> GetAllForRepository(string owner, string na Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); Ensure.ArgumentNotNullOrEmptyString(name, "name"); - return GetAllForRepository(owner,name,ApiOptions.None); + return GetAllForRepository(owner, name, ApiOptions.None); + } + + /// + /// Gets all the events for a given repository + /// + /// + /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository + /// + /// The ID of the repository + /// All the s for the particular repository. + public Task> GetAllForRepository(int repositoryId) + { + return GetAllForRepository(repositoryId, ApiOptions.None); } /// @@ -83,6 +96,21 @@ public Task> GetAllForRepository(string owner, string na return ApiConnection.GetAll(ApiUrls.Events(owner, name), options); } + /// + /// Gets all the events for a given repository + /// + /// + /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository + /// + /// The ID of the repository + /// Options for changing the API response + /// All the s for the particular repository. + public Task> GetAllForRepository(int repositoryId, ApiOptions options) + { + Ensure.ArgumentNotNull(options, "options"); + + return ApiConnection.GetAll(ApiUrls.Events(repositoryId), options); + } /// /// Gets all the event issues for a given repository @@ -101,6 +129,19 @@ public Task> GetAllIssuesForRepository(string owner, str return GetAllIssuesForRepository(owner, name, ApiOptions.None); } + /// + /// Gets all the issue events for a given repository + /// + /// + /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository + /// + /// The ID of the repository + /// All the s for the particular repository. + public Task> GetAllIssuesForRepository(int repositoryId) + { + return GetAllIssuesForRepository(repositoryId, ApiOptions.None); + } + /// /// Gets all the event issues for a given repository /// @@ -120,6 +161,22 @@ public Task> GetAllIssuesForRepository(string owner, str return ApiConnection.GetAll(ApiUrls.IssuesEvents(owner, name), options); } + /// + /// Gets all the issue events for a given repository + /// + /// + /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository + /// + /// The ID of the repository + /// Options for changing the API response + /// All the s for the particular repository. + public Task> GetAllIssuesForRepository(int repositoryId, ApiOptions options) + { + Ensure.ArgumentNotNull(options, "options"); + + return ApiConnection.GetAll(ApiUrls.IssuesEvents(repositoryId), options); + } + /// /// Gets all the events for a given repository network /// @@ -134,7 +191,7 @@ public Task> GetAllForRepositoryNetwork(string owner, st Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); Ensure.ArgumentNotNullOrEmptyString(name, "name"); - return GetAllForRepositoryNetwork(owner,name,ApiOptions.None); + return GetAllForRepositoryNetwork(owner, name, ApiOptions.None); } /// diff --git a/Octokit/Clients/IEventsClient.cs b/Octokit/Clients/IEventsClient.cs index cd49224525..679fb16d5c 100644 --- a/Octokit/Clients/IEventsClient.cs +++ b/Octokit/Clients/IEventsClient.cs @@ -42,6 +42,16 @@ public interface IEventsClient /// All the s for the particular repository. Task> GetAllForRepository(string owner, string name); + /// + /// Gets all the events for a given repository + /// + /// + /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository + /// + /// The ID of the repository + /// All the s for the particular repository. + Task> GetAllForRepository(int repositoryId); + /// /// Gets all the events for a given repository /// @@ -54,6 +64,17 @@ public interface IEventsClient /// All the s for the particular repository. Task> GetAllForRepository(string owner, string name, ApiOptions options); + /// + /// Gets all the events for a given repository + /// + /// + /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository + /// + /// The ID of the repository + /// Options for changing the API response + /// All the s for the particular repository. + Task> GetAllForRepository(int repositoryId, ApiOptions options); + /// /// Gets all the issue events for a given repository /// @@ -65,6 +86,16 @@ public interface IEventsClient /// All the s for the particular repository. Task> GetAllIssuesForRepository(string owner, string name); + /// + /// Gets all the issue events for a given repository + /// + /// + /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository + /// + /// The ID of the repository + /// All the s for the particular repository. + Task> GetAllIssuesForRepository(int repositoryId); + /// /// Gets all the issue events for a given repository /// @@ -77,6 +108,17 @@ public interface IEventsClient /// All the s for the particular repository. Task> GetAllIssuesForRepository(string owner, string name, ApiOptions options); + /// + /// Gets all the issue events for a given repository + /// + /// + /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository + /// + /// The ID of the repository + /// Options for changing the API response + /// All the s for the particular repository. + Task> GetAllIssuesForRepository(int repositoryId, ApiOptions options); + /// /// Gets all the events for a given repository network /// @@ -98,8 +140,8 @@ public interface IEventsClient /// The name of the repository /// Options for changing the API response /// All the s for the particular repository network. - Task> GetAllForRepositoryNetwork(string owner, string name,ApiOptions options); - + Task> GetAllForRepositoryNetwork(string owner, string name, ApiOptions options); + /// /// Gets all the events for a given organization /// From cb1dcf6fd6acccdee40e63342cd23dadfd758bf9 Mon Sep 17 00:00:00 2001 From: Alexander Efremov Date: Mon, 13 Jun 2016 22:53:21 +0700 Subject: [PATCH 2/6] added new unit tests --- Octokit.Tests/Clients/EventsClientTests.cs | 213 ++++++++++++------ .../Reactive/ObservableEventsClientTests.cs | 183 +++++++++++++-- 2 files changed, 311 insertions(+), 85 deletions(-) diff --git a/Octokit.Tests/Clients/EventsClientTests.cs b/Octokit.Tests/Clients/EventsClientTests.cs index d6171804df..6f543f7dc1 100644 --- a/Octokit.Tests/Clients/EventsClientTests.cs +++ b/Octokit.Tests/Clients/EventsClientTests.cs @@ -25,17 +25,18 @@ public void EnsuresNonNullArguments() public class TheGetAllMethod { [Fact] - public void RequestsCorrectUrl() + public async Task RequestsCorrectUrl() { var connection = Substitute.For(); var client = new EventsClient(connection); - client.GetAll(); + await client.GetAll(); connection.Received().GetAll(Arg.Is(u => u.ToString() == "events"), Args.ApiOptions); } + [Fact] - public void RequestsCorrectUrlWithApiOptions() + public async Task RequestsCorrectUrlWithApiOptions() { var connection = Substitute.For(); var client = new EventsClient(connection); @@ -47,7 +48,7 @@ public void RequestsCorrectUrlWithApiOptions() StartPage = 1 }; - client.GetAll(options); + await client.GetAll(options); connection.Received().GetAll(Arg.Is(u => u.ToString() == "events"), options); } @@ -65,17 +66,29 @@ public async Task EnsuresNonNullArguments() public class TheGetAllForRepositoryMethod { [Fact] - public void RequestsCorrectUrl() + public async Task RequestsCorrectUrl() { var connection = Substitute.For(); var client = new EventsClient(connection); - client.GetAllForRepository("fake", "repo"); + await client.GetAllForRepository("fake", "repo"); connection.Received().GetAll(Arg.Is(u => u.ToString() == "repos/fake/repo/events"), Args.ApiOptions); } + + [Fact] + public async Task RequestsCorrectUrlWithRepositoryId() + { + var connection = Substitute.For(); + var client = new EventsClient(connection); + + await client.GetAllForRepository(1); + + connection.Received().GetAll(Arg.Is(u => u.ToString() == "repositories/1/events"), Args.ApiOptions); + } + [Fact] - public void RequestsCorrectUrlWithApiOptions() + public async Task RequestsCorrectUrlWithApiOptions() { var connection = Substitute.For(); var client = new EventsClient(connection); @@ -87,24 +100,46 @@ public void RequestsCorrectUrlWithApiOptions() StartPage = 1 }; - - client.GetAllForRepository("fake", "repo", options); + await client.GetAllForRepository("fake", "repo", options); connection.Received().GetAll(Arg.Is(u => u.ToString() == "repos/fake/repo/events"), options); } [Fact] - public async Task EnsuresArgumentsNotNull() + public async Task RequestsCorrectUrlWithRepositoryIdWithApiOptions() + { + var connection = Substitute.For(); + var client = new EventsClient(connection); + + var options = new ApiOptions + { + PageSize = 1, + PageCount = 1, + StartPage = 1 + }; + + await client.GetAllForRepository(1, options); + + connection.Received().GetAll(Arg.Is(u => u.ToString() == "repositories/1/events"), options); + } + + [Fact] + public async Task EnsuresNonNullArguments() { var connection = Substitute.For(); var client = new EventsClient(connection); await Assert.ThrowsAsync(() => client.GetAllForRepository(null, "name")); - await Assert.ThrowsAsync(() => client.GetAllForRepository("", "name")); await Assert.ThrowsAsync(() => client.GetAllForRepository("owner", null)); + await Assert.ThrowsAsync(() => client.GetAllForRepository(null, "name", ApiOptions.None)); + await Assert.ThrowsAsync(() => client.GetAllForRepository("owner", null, ApiOptions.None)); + await Assert.ThrowsAsync(() => client.GetAllForRepository("owner", "name", null)); + + await Assert.ThrowsAsync(() => client.GetAllForRepository(1, null)); + + await Assert.ThrowsAsync(() => client.GetAllForRepository("", "name")); await Assert.ThrowsAsync(() => client.GetAllForRepository("owner", "")); - await Assert.ThrowsAsync(() => client.GetAllForRepository("owner", "name",null)); - await Assert.ThrowsAsync(() => client.GetAllForRepository("owner", "",ApiOptions.None)); + await Assert.ThrowsAsync(() => client.GetAllForRepository("owner", "", ApiOptions.None)); await Assert.ThrowsAsync(() => client.GetAllForRepository("", "name", ApiOptions.None)); } } @@ -112,17 +147,29 @@ public async Task EnsuresArgumentsNotNull() public class TheGetAllIssuesForRepositoryMethod { [Fact] - public void RequestsCorrectUrl() + public async Task RequestsCorrectUrl() { var connection = Substitute.For(); var client = new EventsClient(connection); - client.GetAllIssuesForRepository("fake", "repo"); + await client.GetAllIssuesForRepository("fake", "repo"); connection.Received().GetAll(Arg.Is(u => u.ToString() == "repos/fake/repo/issues/events"), Args.ApiOptions); } + [Fact] - public void RequestsCorrectUrlWithApiOptions() + public async Task RequestsCorrectUrlWithRepositoryId() + { + var connection = Substitute.For(); + var client = new EventsClient(connection); + + await client.GetAllIssuesForRepository(1); + + connection.Received().GetAll(Arg.Is(u => u.ToString() == "repositories/1/issues/events"), Args.ApiOptions); + } + + [Fact] + public async Task RequestsCorrectUrlWithApiOptions() { var connection = Substitute.For(); var client = new EventsClient(connection); @@ -134,23 +181,45 @@ public void RequestsCorrectUrlWithApiOptions() StartPage = 1 }; - - client.GetAllIssuesForRepository("fake", "repo", options); + await client.GetAllIssuesForRepository("fake", "repo", options); connection.Received().GetAll(Arg.Is(u => u.ToString() == "repos/fake/repo/issues/events"), options); } [Fact] - public async Task EnsuresArgumentsNotNull() + public async Task RequestsCorrectUrlWithRepositoryIdWithApiOptions() + { + var connection = Substitute.For(); + var client = new EventsClient(connection); + + var options = new ApiOptions + { + PageSize = 1, + PageCount = 1, + StartPage = 1 + }; + + await client.GetAllIssuesForRepository(1, options); + + connection.Received().GetAll(Arg.Is(u => u.ToString() == "repositories/1/issues/events"), options); + } + + [Fact] + public async Task EnsuresNonNullArguments() { var connection = Substitute.For(); var client = new EventsClient(connection); await Assert.ThrowsAsync(() => client.GetAllIssuesForRepository(null, "name")); - await Assert.ThrowsAsync(() => client.GetAllIssuesForRepository("", "name")); await Assert.ThrowsAsync(() => client.GetAllIssuesForRepository("owner", null)); - await Assert.ThrowsAsync(() => client.GetAllIssuesForRepository("owner", "")); + await Assert.ThrowsAsync(() => client.GetAllIssuesForRepository(null, "name", ApiOptions.None)); + await Assert.ThrowsAsync(() => client.GetAllIssuesForRepository("owner", null, ApiOptions.None)); await Assert.ThrowsAsync(() => client.GetAllIssuesForRepository("owner", "name", null)); + + await Assert.ThrowsAsync(() => client.GetAllIssuesForRepository(1, null)); + + await Assert.ThrowsAsync(() => client.GetAllIssuesForRepository("", "name")); + await Assert.ThrowsAsync(() => client.GetAllIssuesForRepository("owner", "")); await Assert.ThrowsAsync(() => client.GetAllIssuesForRepository("owner", "", ApiOptions.None)); await Assert.ThrowsAsync(() => client.GetAllIssuesForRepository("", "name", ApiOptions.None)); } @@ -159,18 +228,18 @@ public async Task EnsuresArgumentsNotNull() public class TheGetAllForRepositoryNetworkMethod { [Fact] - public void RequestsCorrectUrl() + public async Task RequestsCorrectUrl() { var connection = Substitute.For(); var client = new EventsClient(connection); - client.GetAllForRepositoryNetwork("fake", "repo"); + await client.GetAllForRepositoryNetwork("fake", "repo"); connection.Received().GetAll(Arg.Is(u => u.ToString() == "networks/fake/repo/events"), Args.ApiOptions); } [Fact] - public void RequestsCorrectUrlWithApiOptions() + public async Task RequestsCorrectUrlWithApiOptions() { var connection = Substitute.For(); var client = new EventsClient(connection); @@ -182,22 +251,26 @@ public void RequestsCorrectUrlWithApiOptions() StartPage = 1 }; - client.GetAllForRepositoryNetwork("fake", "repo", options); + await client.GetAllForRepositoryNetwork("fake", "repo", options); connection.Received().GetAll(Arg.Is(u => u.ToString() == "networks/fake/repo/events"), options); } [Fact] - public async Task EnsuresArgumentsNotNull() + public async Task EnsuresNonNullArguments() { var connection = Substitute.For(); var client = new EventsClient(connection); await Assert.ThrowsAsync(() => client.GetAllForRepositoryNetwork(null, "name")); - await Assert.ThrowsAsync(() => client.GetAllForRepositoryNetwork("", "name")); await Assert.ThrowsAsync(() => client.GetAllForRepositoryNetwork("owner", null)); - await Assert.ThrowsAsync(() => client.GetAllForRepositoryNetwork("owner", "")); + + await Assert.ThrowsAsync(() => client.GetAllForRepositoryNetwork(null, "name", ApiOptions.None)); + await Assert.ThrowsAsync(() => client.GetAllForRepositoryNetwork("owner", null, ApiOptions.None)); await Assert.ThrowsAsync(() => client.GetAllForRepositoryNetwork("owner", "name", null)); + + await Assert.ThrowsAsync(() => client.GetAllForRepositoryNetwork("", "name")); + await Assert.ThrowsAsync(() => client.GetAllForRepositoryNetwork("owner", "")); await Assert.ThrowsAsync(() => client.GetAllForRepositoryNetwork("owner", "", ApiOptions.None)); await Assert.ThrowsAsync(() => client.GetAllForRepositoryNetwork("", "name", ApiOptions.None)); } @@ -206,18 +279,18 @@ public async Task EnsuresArgumentsNotNull() public class TheGetAllForOrganizationMethod { [Fact] - public void RequestsCorrectUrl() + public async Task RequestsCorrectUrl() { var connection = Substitute.For(); var client = new EventsClient(connection); - client.GetAllForOrganization("fake"); + await client.GetAllForOrganization("fake"); connection.Received().GetAll(Arg.Is(u => u.ToString() == "orgs/fake/events"), Args.ApiOptions); } [Fact] - public void RequestsCorrectUrlWithApiOptions() + public async Task RequestsCorrectUrlWithApiOptions() { var connection = Substitute.For(); var client = new EventsClient(connection); @@ -229,20 +302,21 @@ public void RequestsCorrectUrlWithApiOptions() StartPage = 1 }; - client.GetAllForOrganization("fake", options); + await client.GetAllForOrganization("fake", options); connection.Received().GetAll(Arg.Is(u => u.ToString() == "orgs/fake/events"), options); } [Fact] - public async Task EnsuresArgumentsNotNull() + public async Task EnsuresNonNullArguments() { var connection = Substitute.For(); var client = new EventsClient(connection); await Assert.ThrowsAsync(() => client.GetAllForOrganization(null)); - await Assert.ThrowsAsync(() => client.GetAllForOrganization("")); await Assert.ThrowsAsync(() => client.GetAllForOrganization("fake", null)); + + await Assert.ThrowsAsync(() => client.GetAllForOrganization("")); await Assert.ThrowsAsync(() => client.GetAllForOrganization("", ApiOptions.None)); } } @@ -250,18 +324,18 @@ public async Task EnsuresArgumentsNotNull() public class TheGetUserReceivedMethod { [Fact] - public void RequestsCorrectUrl() + public async Task RequestsCorrectUrl() { var connection = Substitute.For(); var client = new EventsClient(connection); - client.GetAllUserReceived("fake"); + await client.GetAllUserReceived("fake"); connection.Received().GetAll(Arg.Is(u => u.ToString() == "users/fake/received_events"), Args.ApiOptions); } [Fact] - public void RequestsCorrectUrlWithApiOptions() + public async Task RequestsCorrectUrlWithApiOptions() { var connection = Substitute.For(); var client = new EventsClient(connection); @@ -273,20 +347,21 @@ public void RequestsCorrectUrlWithApiOptions() StartPage = 1 }; - client.GetAllUserReceived("fake", options); + await client.GetAllUserReceived("fake", options); connection.Received().GetAll(Arg.Is(u => u.ToString() == "users/fake/received_events"), options); } [Fact] - public async Task EnsuresArgumentsNotNull() + public async Task EnsuresNonNullArguments() { var connection = Substitute.For(); var client = new EventsClient(connection); await Assert.ThrowsAsync(() => client.GetAllUserReceived(null)); - await Assert.ThrowsAsync(() => client.GetAllUserReceived("")); await Assert.ThrowsAsync(() => client.GetAllUserReceived("fake", null)); + + await Assert.ThrowsAsync(() => client.GetAllUserReceived("")); await Assert.ThrowsAsync(() => client.GetAllUserReceived("", ApiOptions.None)); } } @@ -294,18 +369,18 @@ public async Task EnsuresArgumentsNotNull() public class TheGetUserReceivedPublicMethod { [Fact] - public void RequestsCorrectUrl() + public async Task RequestsCorrectUrl() { var connection = Substitute.For(); var client = new EventsClient(connection); - client.GetAllUserReceivedPublic("fake"); + await client.GetAllUserReceivedPublic("fake"); connection.Received().GetAll(Arg.Is(u => u.ToString() == "users/fake/received_events/public"), Args.ApiOptions); } [Fact] - public void RequestsCorrectUrlWithApiOptions() + public async Task RequestsCorrectUrlWithApiOptions() { var connection = Substitute.For(); var client = new EventsClient(connection); @@ -317,20 +392,21 @@ public void RequestsCorrectUrlWithApiOptions() StartPage = 1 }; - client.GetAllUserReceivedPublic("fake", options); + await client.GetAllUserReceivedPublic("fake", options); connection.Received().GetAll(Arg.Is(u => u.ToString() == "users/fake/received_events/public"), options); } [Fact] - public async Task EnsuresArgumentsNotNull() + public async Task EnsuresNonNullArguments() { var connection = Substitute.For(); var client = new EventsClient(connection); await Assert.ThrowsAsync(() => client.GetAllUserReceivedPublic(null)); - await Assert.ThrowsAsync(() => client.GetAllUserReceivedPublic("")); await Assert.ThrowsAsync(() => client.GetAllUserReceivedPublic("fake", null)); + + await Assert.ThrowsAsync(() => client.GetAllUserReceivedPublic("")); await Assert.ThrowsAsync(() => client.GetAllUserReceivedPublic("", ApiOptions.None)); } } @@ -338,18 +414,18 @@ public async Task EnsuresArgumentsNotNull() public class TheGetUserPerformedMethod { [Fact] - public void RequestsCorrectUrl() + public async Task RequestsCorrectUrl() { var connection = Substitute.For(); var client = new EventsClient(connection); - client.GetAllUserPerformed("fake"); + await client.GetAllUserPerformed("fake"); connection.Received().GetAll(Arg.Is(u => u.ToString() == "users/fake/events"), Args.ApiOptions); } [Fact] - public void RequestsCorrectUrlWithApiOptions() + public async Task RequestsCorrectUrlWithApiOptions() { var connection = Substitute.For(); var client = new EventsClient(connection); @@ -361,20 +437,21 @@ public void RequestsCorrectUrlWithApiOptions() StartPage = 1 }; - client.GetAllUserPerformed("fake", options); + await client.GetAllUserPerformed("fake", options); connection.Received().GetAll(Arg.Is(u => u.ToString() == "users/fake/events"), options); } [Fact] - public async Task EnsuresArgumentsNotNull() + public async Task EnsuresNonNullArguments() { var connection = Substitute.For(); var client = new EventsClient(connection); await Assert.ThrowsAsync(() => client.GetAllUserPerformed(null)); - await Assert.ThrowsAsync(() => client.GetAllUserPerformed("")); await Assert.ThrowsAsync(() => client.GetAllUserPerformed("fake", null)); + + await Assert.ThrowsAsync(() => client.GetAllUserPerformed("")); await Assert.ThrowsAsync(() => client.GetAllUserPerformed("", ApiOptions.None)); } } @@ -382,18 +459,18 @@ public async Task EnsuresArgumentsNotNull() public class TheGetUserPerformedPublicMethod { [Fact] - public void RequestsCorrectUrl() + public async Task RequestsCorrectUrl() { var connection = Substitute.For(); var client = new EventsClient(connection); - client.GetAllUserPerformedPublic("fake"); + await client.GetAllUserPerformedPublic("fake"); connection.Received().GetAll(Arg.Is(u => u.ToString() == "users/fake/events/public"), Args.ApiOptions); } [Fact] - public void RequestsCorrectUrlWithApiOptions() + public async Task RequestsCorrectUrlWithApiOptions() { var connection = Substitute.For(); var client = new EventsClient(connection); @@ -405,39 +482,40 @@ public void RequestsCorrectUrlWithApiOptions() StartPage = 1 }; - client.GetAllUserPerformedPublic("fake", options); + await client.GetAllUserPerformedPublic("fake", options); connection.Received().GetAll(Arg.Is(u => u.ToString() == "users/fake/events/public"), options); } [Fact] - public async Task EnsuresArgumentsNotNull() + public async Task EnsuresNonNullArguments() { var connection = Substitute.For(); var client = new EventsClient(connection); await Assert.ThrowsAsync(() => client.GetAllUserPerformedPublic(null)); + await Assert.ThrowsAsync(() => client.GetAllUserPerformedPublic("fake", null)); + await Assert.ThrowsAsync(() => client.GetAllUserPerformedPublic("")); - await Assert.ThrowsAsync(() => client.GetAllUserPerformedPublic("fake",null)); - await Assert.ThrowsAsync(() => client.GetAllUserPerformedPublic("",ApiOptions.None)); + await Assert.ThrowsAsync(() => client.GetAllUserPerformedPublic("", ApiOptions.None)); } } public class TheGetForAnOrganizationMethod { [Fact] - public void RequestsCorrectUrl() + public async Task RequestsCorrectUrl() { var connection = Substitute.For(); var client = new EventsClient(connection); - client.GetAllForAnOrganization("fake", "org"); + await client.GetAllForAnOrganization("fake", "org"); connection.Received().GetAll(Arg.Is(u => u.ToString() == "users/fake/events/orgs/org"), Args.ApiOptions); } [Fact] - public void RequestsCorrectUrlWithApiOptions() + public async Task RequestsCorrectUrlWithApiOptions() { var connection = Substitute.For(); var client = new EventsClient(connection); @@ -449,22 +527,25 @@ public void RequestsCorrectUrlWithApiOptions() StartPage = 1 }; - client.GetAllForAnOrganization("fake", "org", options); + await client.GetAllForAnOrganization("fake", "org", options); connection.Received().GetAll(Arg.Is(u => u.ToString() == "users/fake/events/orgs/org"), options); } [Fact] - public async Task EnsuresArgumentsNotNull() + public async Task EnsuresNonNullArguments() { var connection = Substitute.For(); var client = new EventsClient(connection); await Assert.ThrowsAsync(() => client.GetAllForAnOrganization(null, "org")); - await Assert.ThrowsAsync(() => client.GetAllForAnOrganization("", "org")); await Assert.ThrowsAsync(() => client.GetAllForAnOrganization("fake", null)); - await Assert.ThrowsAsync(() => client.GetAllForAnOrganization("fake", "")); + await Assert.ThrowsAsync(() => client.GetAllForAnOrganization(null, "org", ApiOptions.None)); + await Assert.ThrowsAsync(() => client.GetAllForAnOrganization("fake", null, ApiOptions.None)); await Assert.ThrowsAsync(() => client.GetAllForAnOrganization("fake", "org", null)); + + await Assert.ThrowsAsync(() => client.GetAllForAnOrganization("", "org")); + await Assert.ThrowsAsync(() => client.GetAllForAnOrganization("fake", "")); await Assert.ThrowsAsync(() => client.GetAllForAnOrganization("fake", "", ApiOptions.None)); await Assert.ThrowsAsync(() => client.GetAllForAnOrganization("", "org", ApiOptions.None)); } diff --git a/Octokit.Tests/Reactive/ObservableEventsClientTests.cs b/Octokit.Tests/Reactive/ObservableEventsClientTests.cs index bccf493cad..8d06a257d6 100644 --- a/Octokit.Tests/Reactive/ObservableEventsClientTests.cs +++ b/Octokit.Tests/Reactive/ObservableEventsClientTests.cs @@ -32,6 +32,33 @@ public void RequestsCorrectUrl() gitHubClient.Connection.Received(1).Get>(new Uri("events", UriKind.Relative), Args.EmptyDictionary, null); } + + [Fact] + public void RequestsCorrectUrlWithApiOptions() + { + var gitHubClient = Substitute.For(); + var client = new ObservableEventsClient(gitHubClient); + + var options = new ApiOptions + { + PageSize = 1, + PageCount = 1, + StartPage = 1 + }; + + client.GetAll(options); + + gitHubClient.Connection.Received().Get>(new Uri("events", UriKind.Relative), Arg.Is>(d => d.Count == 2), null); + } + + [Fact] + public void EnsuresNonNullArguments() + { + var gitHubClient = Substitute.For(); + var client = new ObservableEventsClient(gitHubClient); + + Assert.Throws(() => client.GetAll(null)); + } } public class TheGetAllForRepositoryMethod @@ -44,19 +71,78 @@ public void RequestsCorrectUrl() client.GetAllForRepository("fake", "repo"); - gitHubClient.Connection.Received(1).Get>(new Uri("repos/fake/repo/events", UriKind.Relative), Args.EmptyDictionary, null); + gitHubClient.Connection.Received(1).Get>(new Uri("repos/fake/repo/events", UriKind.Relative), + Args.EmptyDictionary, null); + } + + [Fact] + public void RequestsCorrectUrlWithRepositoryId() + { + var gitHubClient = Substitute.For(); + var client = new ObservableEventsClient(gitHubClient); + + client.GetAllForRepository(1); + + gitHubClient.Connection.Received(1).Get>(new Uri("repositories/1/events", UriKind.Relative), + Args.EmptyDictionary, null); + } + + [Fact] + public void RequestsCorrectUrlWithApiOptions() + { + var gitHubClient = Substitute.For(); + var client = new ObservableEventsClient(gitHubClient); + + var options = new ApiOptions + { + PageCount = 1, + StartPage = 1, + PageSize = 1 + }; + + client.GetAllForRepository("fake", "repo", options); + + gitHubClient.Connection.Received(1).Get>(new Uri("repos/fake/repo/events", UriKind.Relative), + Arg.Is>(d => d.Count == 2), null); + } + + [Fact] + public void RequestsCorrectUrlWithRepositoryIdWithApiOptions() + { + var gitHubClient = Substitute.For(); + var client = new ObservableEventsClient(gitHubClient); + + var apiOptions = new ApiOptions + { + PageCount = 1, + StartPage = 1, + PageSize = 1 + }; + + client.GetAllForRepository(1, apiOptions); + + gitHubClient.Connection.Received(1).Get>(new Uri("repositories/1/events", UriKind.Relative), + Arg.Is>(d => d.Count == 2), null); } [Fact] - public async Task EnsuresArgumentsNotNull() + public void EnsuresNonNullArguments() { var gitHubClient = Substitute.For(); var client = new ObservableEventsClient(gitHubClient); - await Assert.ThrowsAsync(() => client.GetAllForRepository(null, "name").ToTask()); - await Assert.ThrowsAsync(() => client.GetAllForRepository("", "name").ToTask()); - await Assert.ThrowsAsync(() => client.GetAllForRepository("owner", null).ToTask()); - await Assert.ThrowsAsync(() => client.GetAllForRepository("owner", "").ToTask()); + Assert.Throws(() => client.GetAllForRepository(null, "name")); + Assert.Throws(() => client.GetAllForRepository("owner", null)); + Assert.Throws(() => client.GetAllForRepository(null, "name", ApiOptions.None)); + Assert.Throws(() => client.GetAllForRepository("owner", null, ApiOptions.None)); + Assert.Throws(() => client.GetAllForRepository("owner", "name", null)); + + Assert.Throws(() => client.GetAllForRepository(1, null)); + + Assert.Throws(() => client.GetAllForRepository("", "name")); + Assert.Throws(() => client.GetAllForRepository("owner", "")); + Assert.Throws(() => client.GetAllForRepository("", "name", ApiOptions.None)); + Assert.Throws(() => client.GetAllForRepository("owner", "", ApiOptions.None)); } } @@ -70,19 +156,78 @@ public void RequestsCorrectUrl() client.GetAllIssuesForRepository("fake", "repo"); - gitHubClient.Connection.Received(1).Get>(new Uri("repos/fake/repo/issues/events", UriKind.Relative), Args.EmptyDictionary, null); + gitHubClient.Connection.Received(1).Get>(new Uri("repos/fake/repo/issues/events", UriKind.Relative), + Args.EmptyDictionary, null); } [Fact] - public async Task EnsuresArgumentsNotNull() + public void RequestsCorrectUrlWithRepositoryId() { var gitHubClient = Substitute.For(); var client = new ObservableEventsClient(gitHubClient); - await Assert.ThrowsAsync(() => client.GetAllIssuesForRepository(null, "name").ToTask()); - await Assert.ThrowsAsync(() => client.GetAllIssuesForRepository("", "name").ToTask()); - await Assert.ThrowsAsync(() => client.GetAllIssuesForRepository("owner", null).ToTask()); - await Assert.ThrowsAsync(() => client.GetAllIssuesForRepository("owner", "").ToTask()); + client.GetAllIssuesForRepository(1); + + gitHubClient.Connection.Received(1).Get>(new Uri("repositories/1/issues/events", UriKind.Relative), + Args.EmptyDictionary, null); + } + + [Fact] + public void RequestsCorrectUrlWithApiOptions() + { + var gitHubClient = Substitute.For(); + var client = new ObservableEventsClient(gitHubClient); + + var options = new ApiOptions + { + PageCount = 1, + StartPage = 1, + PageSize = 1 + }; + + client.GetAllIssuesForRepository("fake", "repo", options); + + gitHubClient.Connection.Received(1).Get>(new Uri("repos/fake/repo/issues/events", UriKind.Relative), + Arg.Is>(d => d.Count == 2), null); + } + + [Fact] + public void RequestsCorrectUrlWithRepositoryIdWithApiOptions() + { + var gitHubClient = Substitute.For(); + var client = new ObservableEventsClient(gitHubClient); + + var options = new ApiOptions + { + PageCount = 1, + StartPage = 1, + PageSize = 1 + }; + + client.GetAllIssuesForRepository(1, options); + + gitHubClient.Connection.Received(1).Get>(new Uri("repositories/1/issues/events", UriKind.Relative), + Arg.Is>(d => d.Count == 2), null); + } + + [Fact] + public async Task EnsuresNonNullArguments() + { + var gitHubClient = Substitute.For(); + var client = new ObservableEventsClient(gitHubClient); + + Assert.Throws(() => client.GetAllIssuesForRepository(null, "name")); + Assert.Throws(() => client.GetAllIssuesForRepository("owner", null)); + Assert.Throws(() => client.GetAllIssuesForRepository(null, "name", ApiOptions.None)); + Assert.Throws(() => client.GetAllIssuesForRepository("owner", null, ApiOptions.None)); + Assert.Throws(() => client.GetAllIssuesForRepository("owner", "name", null)); + + Assert.Throws(() => client.GetAllIssuesForRepository(1, null)); + + Assert.Throws(() => client.GetAllIssuesForRepository("", "name")); + Assert.Throws(() => client.GetAllIssuesForRepository("owner", "")); + Assert.Throws(() => client.GetAllIssuesForRepository("", "name", ApiOptions.None)); + Assert.Throws(() => client.GetAllIssuesForRepository("owner", "", ApiOptions.None)); } } @@ -100,7 +245,7 @@ public void RequestsCorrectUrl() } [Fact] - public async Task EnsuresArgumentsNotNull() + public async Task EnsuresNonNullArguments() { var gitHubClient = Substitute.For(); var client = new ObservableEventsClient(gitHubClient); @@ -126,7 +271,7 @@ public void RequestsCorrectUrl() } [Fact] - public async Task EnsuresArgumentsNotNull() + public async Task EnsuresNonNullArguments() { var gitHubClient = Substitute.For(); var client = new ObservableEventsClient(gitHubClient); @@ -150,7 +295,7 @@ public void RequestsCorrectUrl() } [Fact] - public async Task EnsuresArgumentsNotNull() + public async Task EnsuresNonNullArguments() { var gitHubClient = Substitute.For(); var client = new ObservableEventsClient(gitHubClient); @@ -174,7 +319,7 @@ public void RequestsCorrectUrl() } [Fact] - public async Task EnsuresArgumentsNotNull() + public async Task EnsuresNonNullArguments() { var gitHubClient = Substitute.For(); var client = new ObservableEventsClient(gitHubClient); @@ -198,7 +343,7 @@ public void RequestsCorrectUrl() } [Fact] - public async Task EnsuresArgumentsNotNull() + public async Task EnsuresNonNullArguments() { var gitHubClient = Substitute.For(); var client = new ObservableEventsClient(gitHubClient); @@ -222,7 +367,7 @@ public void RequestsCorrectUrl() } [Fact] - public async Task EnsuresArgumentsNotNull() + public async Task EnsuresNonNullArguments() { var gitHubClient = Substitute.For(); var client = new ObservableEventsClient(gitHubClient); @@ -246,7 +391,7 @@ public void RequestsCorrectUrl() } [Fact] - public async Task EnsuresArgumentsNotNull() + public async Task EnsuresNonNullArguments() { var gitHubClient = Substitute.For(); var client = new ObservableEventsClient(gitHubClient); From 4fffe5fc2de5bebbc4067781a5e41c79b4f29dfc Mon Sep 17 00:00:00 2001 From: Alexander Efremov Date: Mon, 13 Jun 2016 23:33:46 +0700 Subject: [PATCH 3/6] added new integration tests --- .../Clients/EventsClientTests.cs | 278 +++++++++++++++++- 1 file changed, 276 insertions(+), 2 deletions(-) diff --git a/Octokit.Tests.Integration/Clients/EventsClientTests.cs b/Octokit.Tests.Integration/Clients/EventsClientTests.cs index 10805a7677..d8cc1f0c25 100644 --- a/Octokit.Tests.Integration/Clients/EventsClientTests.cs +++ b/Octokit.Tests.Integration/Clients/EventsClientTests.cs @@ -1,5 +1,4 @@ -using System; -using System.Collections.Generic; +using System.Collections.Generic; using System.Linq; using System.Threading.Tasks; using Xunit; @@ -15,8 +14,283 @@ public async Task ReturnsACollection() { var github = Helper.GetAuthenticatedClient(); var events = await github.Activity.Events.GetAllUserPerformed("shiftkey"); + + Assert.NotEmpty(events); + } + } + + public class TheGetAllForRepositoryMethod + { + [IntegrationTest] + public async Task CanListEvents() + { + var github = Helper.GetAuthenticatedClient(); + var events = await github.Activity.Events.GetAllForRepository("octokit", "octokit.net"); + + Assert.NotEmpty(events); + } + + [IntegrationTest] + public async Task CanListEventsWithRepositoryId() + { + var github = Helper.GetAuthenticatedClient(); + var events = await github.Activity.Events.GetAllForRepository(7528679); + Assert.NotEmpty(events); } + + [IntegrationTest] + public async Task ReturnsCorrectCountOfEventsWithoutStart() + { + var github = Helper.GetAuthenticatedClient(); + + var options = new ApiOptions + { + PageSize = 3, + PageCount = 1 + }; + + var eventInfos = await github.Activity.Events.GetAllForRepository("octokit", "octokit.net", options); + + Assert.Equal(3, eventInfos.Count); + } + + [IntegrationTest] + public async Task ReturnsCorrectCountOfEventsWithoutStartWitRepositoryId() + { + var github = Helper.GetAuthenticatedClient(); + + var options = new ApiOptions + { + PageSize = 3, + PageCount = 1 + }; + + var eventInfos = await github.Activity.Events.GetAllForRepository(7528679, options); + + Assert.Equal(3, eventInfos.Count); + } + + [IntegrationTest] + public async Task ReturnsCorrectCountOfEventsWithStart() + { + var github = Helper.GetAuthenticatedClient(); + + var options = new ApiOptions + { + PageSize = 2, + PageCount = 1, + StartPage = 2 + }; + + var eventInfos = await github.Activity.Events.GetAllForRepository("octokit", "octokit.net", options); + + Assert.Equal(2, eventInfos.Count); + } + + [IntegrationTest] + public async Task ReturnsCorrectCountOfEventsWithStartWithRepositoryId() + { + var github = Helper.GetAuthenticatedClient(); + + var options = new ApiOptions + { + PageSize = 2, + PageCount = 1, + StartPage = 2 + }; + + var eventInfos = await github.Activity.Events.GetAllForRepository(7528679, options); + + Assert.Equal(2, eventInfos.Count); + } + + [IntegrationTest] + public async Task ReturnsDistinctEventsBasedOnStartPage() + { + var github = Helper.GetAuthenticatedClient(); + + var startOptions = new ApiOptions + { + PageSize = 1, + PageCount = 1 + }; + + var firstPage = await github.Activity.Events.GetAllForRepository("octokit", "octokit.net", startOptions); + + var skipStartOptions = new ApiOptions + { + PageSize = 1, + PageCount = 1, + StartPage = 2 + }; + + var secondPage = await github.Activity.Events.GetAllForRepository("octokit", "octokit.net", skipStartOptions); + + Assert.NotEqual(firstPage[0].Id, secondPage[0].Id); + } + + [IntegrationTest] + public async Task ReturnsDistinctEventsBasedOnStartPageWithRepositoryId() + { + var github = Helper.GetAuthenticatedClient(); + + var startOptions = new ApiOptions + { + PageSize = 1, + PageCount = 1 + }; + + var firstPage = await github.Activity.Events.GetAllForRepository(7528679, startOptions); + + var skipStartOptions = new ApiOptions + { + PageSize = 1, + PageCount = 1, + StartPage = 2 + }; + + var secondPage = await github.Activity.Events.GetAllForRepository(7528679, skipStartOptions); + + Assert.NotEqual(firstPage[0].Id, secondPage[0].Id); + } + } + + public class TheGetAllIssuesForRepositoryMethod + { + [IntegrationTest(Skip = "Fails because of SimpleJsonSerializer, see https://github.com/octokit/octokit.net/issues/1374 for details.")] + public async Task CanListIssues() + { + var github = Helper.GetAuthenticatedClient(); + var issues = await github.Activity.Events.GetAllIssuesForRepository("octokit", "octokit.net"); + + Assert.NotEmpty(issues); + } + + [IntegrationTest(Skip = "Fails because of SimpleJsonSerializer, see https://github.com/octokit/octokit.net/issues/1374 for details.")] + public async Task CanListIssuesWithRepositoryId() + { + var github = Helper.GetAuthenticatedClient(); + var issues = await github.Activity.Events.GetAllIssuesForRepository(7528679); + + Assert.NotEmpty(issues); + } + + [IntegrationTest(Skip = "Fails because of SimpleJsonSerializer, see https://github.com/octokit/octokit.net/issues/1374 for details.")] + public async Task ReturnsCorrectCountOfEventsWithoutStart() + { + var github = Helper.GetAuthenticatedClient(); + + var options = new ApiOptions + { + PageSize = 3, + PageCount = 1 + }; + + var eventInfos = await github.Activity.Events.GetAllIssuesForRepository("octokit", "octokit.net", options); + + Assert.Equal(3, eventInfos.Count); + } + + [IntegrationTest(Skip = "Fails because of SimpleJsonSerializer, see https://github.com/octokit/octokit.net/issues/1374 for details.")] + public async Task ReturnsCorrectCountOfEventsWithoutStartWitRepositoryId() + { + var github = Helper.GetAuthenticatedClient(); + + var options = new ApiOptions + { + PageSize = 3, + PageCount = 1 + }; + + var eventInfos = await github.Activity.Events.GetAllIssuesForRepository(7528679, options); + + Assert.Equal(3, eventInfos.Count); + } + + [IntegrationTest(Skip = "Fails because of SimpleJsonSerializer, see https://github.com/octokit/octokit.net/issues/1374 for details.")] + public async Task ReturnsCorrectCountOfEventsWithStart() + { + var github = Helper.GetAuthenticatedClient(); + + var options = new ApiOptions + { + PageSize = 2, + PageCount = 1, + StartPage = 2 + }; + + var eventInfos = await github.Activity.Events.GetAllIssuesForRepository("octokit", "octokit.net", options); + + Assert.Equal(2, eventInfos.Count); + } + + [IntegrationTest(Skip = "Fails because of SimpleJsonSerializer, see https://github.com/octokit/octokit.net/issues/1374 for details.")] + public async Task ReturnsCorrectCountOfEventsWithStartWithRepositoryId() + { + var github = Helper.GetAuthenticatedClient(); + + var options = new ApiOptions + { + PageSize = 2, + PageCount = 1, + StartPage = 2 + }; + + var eventInfos = await github.Activity.Events.GetAllIssuesForRepository(7528679, options); + + Assert.Equal(2, eventInfos.Count); + } + + [IntegrationTest(Skip = "Fails because of SimpleJsonSerializer, see https://github.com/octokit/octokit.net/issues/1374 for details.")] + public async Task ReturnsDistinctEventsBasedOnStartPage() + { + var github = Helper.GetAuthenticatedClient(); + + var startOptions = new ApiOptions + { + PageSize = 1, + PageCount = 1 + }; + + var firstPage = await github.Activity.Events.GetAllIssuesForRepository("octokit", "octokit.net", startOptions); + + var skipStartOptions = new ApiOptions + { + PageSize = 1, + PageCount = 1, + StartPage = 2 + }; + + var secondPage = await github.Activity.Events.GetAllIssuesForRepository("octokit", "octokit.net", skipStartOptions); + + Assert.NotEqual(firstPage[0].Id, secondPage[0].Id); + } + + [IntegrationTest(Skip = "Fails because of SimpleJsonSerializer, see https://github.com/octokit/octokit.net/issues/1374 for details.")] + public async Task ReturnsDistinctEventsBasedOnStartPageWithRepositoryId() + { + var github = Helper.GetAuthenticatedClient(); + + var startOptions = new ApiOptions + { + PageSize = 1, + PageCount = 1 + }; + + var firstPage = await github.Activity.Events.GetAllIssuesForRepository(7528679, startOptions); + + var skipStartOptions = new ApiOptions + { + PageSize = 1, + PageCount = 1, + StartPage = 2 + }; + + var secondPage = await github.Activity.Events.GetAllIssuesForRepository(7528679, skipStartOptions); + + Assert.NotEqual(firstPage[0].Id, secondPage[0].Id); + } } public class EventPayloads From 7c8f8341e9d1153bd3594c2752c813ca2e0642fd Mon Sep 17 00:00:00 2001 From: Brendan Forster Date: Tue, 14 Jun 2016 10:24:29 +1000 Subject: [PATCH 4/6] lock to an earlier version of mono (#1376) --- .travis.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.travis.yml b/.travis.yml index 5acd1c0680..1244d3ebeb 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,4 +1,6 @@ language: csharp +mono: + - 4.2.3 sudo: false # use the new container-based Travis infrastructure os: From f8d792e47e0e1b10bd1c74af8032cca2e6ee29b8 Mon Sep 17 00:00:00 2001 From: Alexander Efremov Date: Fri, 17 Jun 2016 05:58:15 +0700 Subject: [PATCH 5/6] cleared tags --- .../Clients/IObservableEventsClient.cs | 48 +++++++++---------- .../Clients/ObservableEventsClient.cs | 48 +++++++++---------- Octokit/Clients/EventsClient.cs | 48 +++++++++---------- Octokit/Clients/IEventsClient.cs | 48 +++++++++---------- 4 files changed, 96 insertions(+), 96 deletions(-) diff --git a/Octokit.Reactive/Clients/IObservableEventsClient.cs b/Octokit.Reactive/Clients/IObservableEventsClient.cs index 14b296e0bd..e5aa58f8d5 100644 --- a/Octokit.Reactive/Clients/IObservableEventsClient.cs +++ b/Octokit.Reactive/Clients/IObservableEventsClient.cs @@ -16,7 +16,7 @@ public interface IObservableEventsClient /// /// http://developer.github.com/v3/activity/events/#list-public-events /// - /// All the public s for the particular user. + /// [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")] IObservable GetAll(); @@ -27,7 +27,7 @@ public interface IObservableEventsClient /// http://developer.github.com/v3/activity/events/#list-public-events /// /// Options for changing the API response - /// All the public s for the particular user. + /// IObservable GetAll(ApiOptions options); /// @@ -38,7 +38,7 @@ public interface IObservableEventsClient /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository. + /// IObservable GetAllForRepository(string owner, string name); /// @@ -48,7 +48,7 @@ public interface IObservableEventsClient /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository /// /// The ID of the repository - /// All the s for the particular repository. + /// IObservable GetAllForRepository(int repositoryId); /// @@ -60,7 +60,7 @@ public interface IObservableEventsClient /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository. + /// IObservable GetAllForRepository(string owner, string name, ApiOptions options); /// @@ -71,7 +71,7 @@ public interface IObservableEventsClient /// /// The ID of the repository /// Options for changing the API response - /// All the s for the particular repository. + /// IObservable GetAllForRepository(int repositoryId, ApiOptions options); /// @@ -82,7 +82,7 @@ public interface IObservableEventsClient /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository. + /// IObservable GetAllIssuesForRepository(string owner, string name); /// @@ -92,7 +92,7 @@ public interface IObservableEventsClient /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository /// /// The ID of the repository - /// All the s for the particular repository. + /// IObservable GetAllIssuesForRepository(int repositoryId); /// @@ -104,7 +104,7 @@ public interface IObservableEventsClient /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository. + /// IObservable GetAllIssuesForRepository(string owner, string name, ApiOptions options); /// @@ -115,7 +115,7 @@ public interface IObservableEventsClient /// /// The ID of the repository /// Options for changing the API response - /// All the s for the particular repository. + /// IObservable GetAllIssuesForRepository(int repositoryId, ApiOptions options); /// @@ -126,7 +126,7 @@ public interface IObservableEventsClient /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository network. + /// IObservable GetAllForRepositoryNetwork(string owner, string name); /// @@ -138,7 +138,7 @@ public interface IObservableEventsClient /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository network. + /// IObservable GetAllForRepositoryNetwork(string owner, string name, ApiOptions options); /// @@ -148,7 +148,7 @@ public interface IObservableEventsClient /// http://developer.github.com/v3/activity/events/#list-public-events-for-an-organization /// /// The name of the organization - /// All the s for the particular organization. + /// IObservable GetAllForOrganization(string organization); /// @@ -159,7 +159,7 @@ public interface IObservableEventsClient /// /// The name of the organization /// Options for changing the API response - /// All the s for the particular organization. + /// IObservable GetAllForOrganization(string organization, ApiOptions options); /// @@ -169,7 +169,7 @@ public interface IObservableEventsClient /// http://developer.github.com/v3/activity/events/#list-events-that-a-user-has-received /// /// The login of the user - /// All the s that a particular user has received. + /// IObservable GetAllUserReceived(string user); /// @@ -180,7 +180,7 @@ public interface IObservableEventsClient /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has received. + /// IObservable GetAllUserReceived(string user, ApiOptions options); /// @@ -190,7 +190,7 @@ public interface IObservableEventsClient /// http://developer.github.com/v3/activity/events/#list-public-events-that-a-user-has-received /// /// The login of the user - /// All the s that a particular user has received. + /// IObservable GetAllUserReceivedPublic(string user); /// @@ -201,7 +201,7 @@ public interface IObservableEventsClient /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has received. + /// IObservable GetAllUserReceivedPublic(string user, ApiOptions options); /// @@ -211,7 +211,7 @@ public interface IObservableEventsClient /// http://developer.github.com/v3/activity/events/#list-events-performed-by-a-user /// /// The login of the user - /// All the s that a particular user has performed. + /// IObservable GetAllUserPerformed(string user); /// @@ -222,7 +222,7 @@ public interface IObservableEventsClient /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has performed. + /// IObservable GetAllUserPerformed(string user, ApiOptions options); /// @@ -232,7 +232,7 @@ public interface IObservableEventsClient /// http://developer.github.com/v3/activity/events/#list-public-events-performed-by-a-user /// /// The login of the user - /// All the public s that a particular user has performed. + /// IObservable GetAllUserPerformedPublic(string user); /// @@ -243,7 +243,7 @@ public interface IObservableEventsClient /// /// The login of the user /// Options for changing the API response - /// All the public s that a particular user has performed. + /// IObservable GetAllUserPerformedPublic(string user, ApiOptions options); /// @@ -254,7 +254,7 @@ public interface IObservableEventsClient /// /// The login of the user /// The name of the organization - /// All the public s that are associated with an organization. + /// IObservable GetAllForAnOrganization(string user, string organization); /// @@ -266,7 +266,7 @@ public interface IObservableEventsClient /// The login of the user /// The name of the organization /// Options for changing the API response - /// All the public s that are associated with an organization. + /// IObservable GetAllForAnOrganization(string user, string organization, ApiOptions options); } } \ No newline at end of file diff --git a/Octokit.Reactive/Clients/ObservableEventsClient.cs b/Octokit.Reactive/Clients/ObservableEventsClient.cs index 318adce7df..d3769bc720 100644 --- a/Octokit.Reactive/Clients/ObservableEventsClient.cs +++ b/Octokit.Reactive/Clients/ObservableEventsClient.cs @@ -26,7 +26,7 @@ public ObservableEventsClient(IGitHubClient client) /// /// http://developer.github.com/v3/activity/events/#list-public-events /// - /// All the public s for the particular user. + /// public IObservable GetAll() { return GetAll(ApiOptions.None); @@ -39,7 +39,7 @@ public IObservable GetAll() /// http://developer.github.com/v3/activity/events/#list-public-events /// /// Options for changing the API response - /// All the public s for the particular user. + /// public IObservable GetAll(ApiOptions options) { Ensure.ArgumentNotNull(options, "options"); @@ -55,7 +55,7 @@ public IObservable GetAll(ApiOptions options) /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository. + /// public IObservable GetAllForRepository(string owner, string name) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -71,7 +71,7 @@ public IObservable GetAllForRepository(string owner, string name) /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository /// /// The ID of the repository - /// All the s for the particular repository. + /// public IObservable GetAllForRepository(int repositoryId) { return GetAllForRepository(repositoryId, ApiOptions.None); @@ -86,7 +86,7 @@ public IObservable GetAllForRepository(int repositoryId) /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository. + /// public IObservable GetAllForRepository(string owner, string name, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -104,7 +104,7 @@ public IObservable GetAllForRepository(string owner, string name, ApiO /// /// The ID of the repository /// Options for changing the API response - /// All the s for the particular repository. + /// public IObservable GetAllForRepository(int repositoryId, ApiOptions options) { Ensure.ArgumentNotNull(options, "options"); @@ -120,7 +120,7 @@ public IObservable GetAllForRepository(int repositoryId, ApiOptions op /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository. + /// public IObservable GetAllIssuesForRepository(string owner, string name) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -136,7 +136,7 @@ public IObservable GetAllIssuesForRepository(string owner, string name /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository /// /// The ID of the repository - /// All the s for the particular repository. + /// public IObservable GetAllIssuesForRepository(int repositoryId) { return GetAllIssuesForRepository(repositoryId, ApiOptions.None); @@ -151,7 +151,7 @@ public IObservable GetAllIssuesForRepository(int repositoryId) /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository. + /// public IObservable GetAllIssuesForRepository(string owner, string name, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -169,7 +169,7 @@ public IObservable GetAllIssuesForRepository(string owner, string name /// /// The ID of the repository /// Options for changing the API response - /// All the s for the particular repository. + /// public IObservable GetAllIssuesForRepository(int repositoryId, ApiOptions options) { Ensure.ArgumentNotNull(options, "options"); @@ -185,7 +185,7 @@ public IObservable GetAllIssuesForRepository(int repositoryId, ApiOpti /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository network. + /// public IObservable GetAllForRepositoryNetwork(string owner, string name) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -203,7 +203,7 @@ public IObservable GetAllForRepositoryNetwork(string owner, string nam /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository network. + /// public IObservable GetAllForRepositoryNetwork(string owner, string name, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -220,7 +220,7 @@ public IObservable GetAllForRepositoryNetwork(string owner, string nam /// http://developer.github.com/v3/activity/events/#list-public-events-for-an-organization /// /// The name of the organization - /// All the s for the particular organization. + /// public IObservable GetAllForOrganization(string organization) { Ensure.ArgumentNotNullOrEmptyString(organization, "organization"); @@ -236,7 +236,7 @@ public IObservable GetAllForOrganization(string organization) /// /// The name of the organization /// Options for changing the API response - /// All the s for the particular organization. + /// public IObservable GetAllForOrganization(string organization, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(organization, "organization"); @@ -252,7 +252,7 @@ public IObservable GetAllForOrganization(string organization, ApiOptio /// http://developer.github.com/v3/activity/events/#list-events-that-a-user-has-received /// /// The login of the user - /// All the s that a particular user has received. + /// public IObservable GetAllUserReceived(string user) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -268,7 +268,7 @@ public IObservable GetAllUserReceived(string user) /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has received. + /// public IObservable GetAllUserReceived(string user, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -284,7 +284,7 @@ public IObservable GetAllUserReceived(string user, ApiOptions options) /// http://developer.github.com/v3/activity/events/#list-public-events-that-a-user-has-received /// /// The login of the user - /// All the s that a particular user has received. + /// public IObservable GetAllUserReceivedPublic(string user) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -300,7 +300,7 @@ public IObservable GetAllUserReceivedPublic(string user) /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has received. + /// public IObservable GetAllUserReceivedPublic(string user, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -316,7 +316,7 @@ public IObservable GetAllUserReceivedPublic(string user, ApiOptions op /// http://developer.github.com/v3/activity/events/#list-events-performed-by-a-user /// /// The login of the user - /// All the s that a particular user has performed. + /// public IObservable GetAllUserPerformed(string user) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -332,7 +332,7 @@ public IObservable GetAllUserPerformed(string user) /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has performed. + /// public IObservable GetAllUserPerformed(string user, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -348,7 +348,7 @@ public IObservable GetAllUserPerformed(string user, ApiOptions options /// http://developer.github.com/v3/activity/events/#list-public-events-performed-by-a-user /// /// The login of the user - /// All the public s that a particular user has performed. + /// public IObservable GetAllUserPerformedPublic(string user) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -364,7 +364,7 @@ public IObservable GetAllUserPerformedPublic(string user) /// /// The login of the user /// Options for changing the API response - /// All the public s that a particular user has performed. + /// public IObservable GetAllUserPerformedPublic(string user, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -381,7 +381,7 @@ public IObservable GetAllUserPerformedPublic(string user, ApiOptions o /// /// The login of the user /// The name of the organization - /// All the public s that are associated with an organization. + /// public IObservable GetAllForAnOrganization(string user, string organization) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -399,7 +399,7 @@ public IObservable GetAllForAnOrganization(string user, string organiz /// The login of the user /// The name of the organization /// Options for changing the API response - /// All the public s that are associated with an organization. + /// public IObservable GetAllForAnOrganization(string user, string organization, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); diff --git a/Octokit/Clients/EventsClient.cs b/Octokit/Clients/EventsClient.cs index d6c9147428..0edf9d51b2 100644 --- a/Octokit/Clients/EventsClient.cs +++ b/Octokit/Clients/EventsClient.cs @@ -26,7 +26,7 @@ public EventsClient(IApiConnection apiConnection) /// /// http://developer.github.com/v3/activity/events/#list-public-events /// - /// All the public s for the particular user. + /// public Task> GetAll() { return GetAll(ApiOptions.None); @@ -39,7 +39,7 @@ public Task> GetAll() /// http://developer.github.com/v3/activity/events/#list-public-events /// /// Options for changing the API response - /// All the public s for the particular user. + /// public Task> GetAll(ApiOptions options) { Ensure.ArgumentNotNull(options, "options"); @@ -55,7 +55,7 @@ public Task> GetAll(ApiOptions options) /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository. + /// public Task> GetAllForRepository(string owner, string name) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -71,7 +71,7 @@ public Task> GetAllForRepository(string owner, string na /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository /// /// The ID of the repository - /// All the s for the particular repository. + /// public Task> GetAllForRepository(int repositoryId) { return GetAllForRepository(repositoryId, ApiOptions.None); @@ -86,7 +86,7 @@ public Task> GetAllForRepository(int repositoryId) /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository. + /// public Task> GetAllForRepository(string owner, string name, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -104,7 +104,7 @@ public Task> GetAllForRepository(string owner, string na /// /// The ID of the repository /// Options for changing the API response - /// All the s for the particular repository. + /// public Task> GetAllForRepository(int repositoryId, ApiOptions options) { Ensure.ArgumentNotNull(options, "options"); @@ -120,7 +120,7 @@ public Task> GetAllForRepository(int repositoryId, ApiOp /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository. + /// public Task> GetAllIssuesForRepository(string owner, string name) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -136,7 +136,7 @@ public Task> GetAllIssuesForRepository(string owner, str /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository /// /// The ID of the repository - /// All the s for the particular repository. + /// public Task> GetAllIssuesForRepository(int repositoryId) { return GetAllIssuesForRepository(repositoryId, ApiOptions.None); @@ -151,7 +151,7 @@ public Task> GetAllIssuesForRepository(int repositoryId) /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository. + /// public Task> GetAllIssuesForRepository(string owner, string name, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -169,7 +169,7 @@ public Task> GetAllIssuesForRepository(string owner, str /// /// The ID of the repository /// Options for changing the API response - /// All the s for the particular repository. + /// public Task> GetAllIssuesForRepository(int repositoryId, ApiOptions options) { Ensure.ArgumentNotNull(options, "options"); @@ -185,7 +185,7 @@ public Task> GetAllIssuesForRepository(int repositoryId, /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository network. + /// public Task> GetAllForRepositoryNetwork(string owner, string name) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -203,7 +203,7 @@ public Task> GetAllForRepositoryNetwork(string owner, st /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository network. + /// public Task> GetAllForRepositoryNetwork(string owner, string name, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -220,7 +220,7 @@ public Task> GetAllForRepositoryNetwork(string owner, st /// http://developer.github.com/v3/activity/events/#list-public-events-for-an-organization /// /// The name of the organization - /// All the s for the particular organization. + /// public Task> GetAllForOrganization(string organization) { Ensure.ArgumentNotNullOrEmptyString(organization, "organization"); @@ -236,7 +236,7 @@ public Task> GetAllForOrganization(string organization) /// /// The name of the organization /// Options for changing the API response - /// All the s for the particular organization. + /// public Task> GetAllForOrganization(string organization, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(organization, "organization"); @@ -252,7 +252,7 @@ public Task> GetAllForOrganization(string organization, /// http://developer.github.com/v3/activity/events/#list-events-that-a-user-has-received /// /// The login of the user - /// All the s that a particular user has received. + /// public Task> GetAllUserReceived(string user) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -268,7 +268,7 @@ public Task> GetAllUserReceived(string user) /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has received. + /// public Task> GetAllUserReceived(string user, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -284,7 +284,7 @@ public Task> GetAllUserReceived(string user, ApiOptions /// http://developer.github.com/v3/activity/events/#list-public-events-that-a-user-has-received /// /// The login of the user - /// All the s that a particular user has received. + /// public Task> GetAllUserReceivedPublic(string user) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -300,7 +300,7 @@ public Task> GetAllUserReceivedPublic(string user) /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has received. + /// public Task> GetAllUserReceivedPublic(string user, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -316,7 +316,7 @@ public Task> GetAllUserReceivedPublic(string user, ApiOp /// http://developer.github.com/v3/activity/events/#list-events-performed-by-a-user /// /// The login of the user - /// All the s that a particular user has performed. + /// public Task> GetAllUserPerformed(string user) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -332,7 +332,7 @@ public Task> GetAllUserPerformed(string user) /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has performed. + /// public Task> GetAllUserPerformed(string user, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -348,7 +348,7 @@ public Task> GetAllUserPerformed(string user, ApiOptions /// http://developer.github.com/v3/activity/events/#list-public-events-performed-by-a-user /// /// The login of the user - /// All the public s that a particular user has performed. + /// public Task> GetAllUserPerformedPublic(string user) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -364,7 +364,7 @@ public Task> GetAllUserPerformedPublic(string user) /// /// The login of the user /// Options for changing the API response - /// All the public s that a particular user has performed. + /// public Task> GetAllUserPerformedPublic(string user, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -381,7 +381,7 @@ public Task> GetAllUserPerformedPublic(string user, ApiO /// /// The login of the user /// The name of the organization - /// All the public s that are associated with an organization. + /// public Task> GetAllForAnOrganization(string user, string organization) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -399,7 +399,7 @@ public Task> GetAllForAnOrganization(string user, string /// The login of the user /// The name of the organization /// Options for changing the API response - /// All the public s that are associated with an organization. + /// public Task> GetAllForAnOrganization(string user, string organization, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); diff --git a/Octokit/Clients/IEventsClient.cs b/Octokit/Clients/IEventsClient.cs index 679fb16d5c..6e597b8ddd 100644 --- a/Octokit/Clients/IEventsClient.cs +++ b/Octokit/Clients/IEventsClient.cs @@ -17,7 +17,7 @@ public interface IEventsClient /// /// http://developer.github.com/v3/activity/events/#list-public-events /// - /// All the public s for the particular user. + /// [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")] Task> GetAll(); @@ -28,7 +28,7 @@ public interface IEventsClient /// http://developer.github.com/v3/activity/events/#list-public-events /// /// Options for changing the API response - /// All the public s for the particular user. + /// Task> GetAll(ApiOptions options); /// @@ -39,7 +39,7 @@ public interface IEventsClient /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository. + /// Task> GetAllForRepository(string owner, string name); /// @@ -49,7 +49,7 @@ public interface IEventsClient /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository /// /// The ID of the repository - /// All the s for the particular repository. + /// Task> GetAllForRepository(int repositoryId); /// @@ -61,7 +61,7 @@ public interface IEventsClient /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository. + /// Task> GetAllForRepository(string owner, string name, ApiOptions options); /// @@ -72,7 +72,7 @@ public interface IEventsClient /// /// The ID of the repository /// Options for changing the API response - /// All the s for the particular repository. + /// Task> GetAllForRepository(int repositoryId, ApiOptions options); /// @@ -83,7 +83,7 @@ public interface IEventsClient /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository. + /// Task> GetAllIssuesForRepository(string owner, string name); /// @@ -93,7 +93,7 @@ public interface IEventsClient /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository /// /// The ID of the repository - /// All the s for the particular repository. + /// Task> GetAllIssuesForRepository(int repositoryId); /// @@ -105,7 +105,7 @@ public interface IEventsClient /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository. + /// Task> GetAllIssuesForRepository(string owner, string name, ApiOptions options); /// @@ -116,7 +116,7 @@ public interface IEventsClient /// /// The ID of the repository /// Options for changing the API response - /// All the s for the particular repository. + /// Task> GetAllIssuesForRepository(int repositoryId, ApiOptions options); /// @@ -127,7 +127,7 @@ public interface IEventsClient /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository network. + /// Task> GetAllForRepositoryNetwork(string owner, string name); /// @@ -139,7 +139,7 @@ public interface IEventsClient /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository network. + /// Task> GetAllForRepositoryNetwork(string owner, string name, ApiOptions options); /// @@ -149,7 +149,7 @@ public interface IEventsClient /// http://developer.github.com/v3/activity/events/#list-public-events-for-an-organization /// /// The name of the organization - /// All the s for the particular organization. + /// Task> GetAllForOrganization(string organization); /// @@ -160,7 +160,7 @@ public interface IEventsClient /// /// The name of the organization /// Options for changing the API response - /// All the s for the particular organization. + /// Task> GetAllForOrganization(string organization, ApiOptions options); /// @@ -170,7 +170,7 @@ public interface IEventsClient /// http://developer.github.com/v3/activity/events/#list-events-that-a-user-has-received /// /// The login of the user - /// All the s that a particular user has received. + /// Task> GetAllUserReceived(string user); /// @@ -181,7 +181,7 @@ public interface IEventsClient /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has received. + /// Task> GetAllUserReceived(string user, ApiOptions options); /// @@ -191,7 +191,7 @@ public interface IEventsClient /// http://developer.github.com/v3/activity/events/#list-public-events-that-a-user-has-received /// /// The login of the user - /// All the s that a particular user has received. + /// Task> GetAllUserReceivedPublic(string user); /// @@ -202,7 +202,7 @@ public interface IEventsClient /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has received. + /// Task> GetAllUserReceivedPublic(string user, ApiOptions options); /// @@ -212,7 +212,7 @@ public interface IEventsClient /// http://developer.github.com/v3/activity/events/#list-events-performed-by-a-user /// /// The login of the user - /// All the s that a particular user has performed. + /// Task> GetAllUserPerformed(string user); /// @@ -223,7 +223,7 @@ public interface IEventsClient /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has performed. + /// Task> GetAllUserPerformed(string user, ApiOptions options); /// @@ -233,7 +233,7 @@ public interface IEventsClient /// http://developer.github.com/v3/activity/events/#list-public-events-performed-by-a-user /// /// The login of the user - /// All the public s that a particular user has performed. + /// Task> GetAllUserPerformedPublic(string user); /// @@ -244,7 +244,7 @@ public interface IEventsClient /// /// The login of the user /// Options for changing the API response - /// All the public s that a particular user has performed. + /// Task> GetAllUserPerformedPublic(string user, ApiOptions options); /// @@ -255,7 +255,7 @@ public interface IEventsClient /// /// The login of the user /// The name of the organization - /// All the public s that are associated with an organization. + /// Task> GetAllForAnOrganization(string user, string organization); /// @@ -267,7 +267,7 @@ public interface IEventsClient /// The login of the user /// The name of the organization /// Options for changing the API response - /// All the public s that are associated with an organization. + /// Task> GetAllForAnOrganization(string user, string organization, ApiOptions options); } } \ No newline at end of file From 89a70ffc36099a09ff8bd8fdafc23a2398c7728d Mon Sep 17 00:00:00 2001 From: "aedampir@gmail.com" Date: Sat, 25 Jun 2016 20:42:53 +0700 Subject: [PATCH 6/6] removed tags --- .../Clients/IObservableEventsClient.cs | 24 ------------------- .../Clients/ObservableEventsClient.cs | 24 ------------------- Octokit/Clients/EventsClient.cs | 23 ------------------ Octokit/Clients/IEventsClient.cs | 23 ------------------ 4 files changed, 94 deletions(-) diff --git a/Octokit.Reactive/Clients/IObservableEventsClient.cs b/Octokit.Reactive/Clients/IObservableEventsClient.cs index 14b296e0bd..1a30e855a3 100644 --- a/Octokit.Reactive/Clients/IObservableEventsClient.cs +++ b/Octokit.Reactive/Clients/IObservableEventsClient.cs @@ -16,7 +16,6 @@ public interface IObservableEventsClient /// /// http://developer.github.com/v3/activity/events/#list-public-events /// - /// All the public s for the particular user. [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")] IObservable GetAll(); @@ -27,7 +26,6 @@ public interface IObservableEventsClient /// http://developer.github.com/v3/activity/events/#list-public-events /// /// Options for changing the API response - /// All the public s for the particular user. IObservable GetAll(ApiOptions options); /// @@ -38,7 +36,6 @@ public interface IObservableEventsClient /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository. IObservable GetAllForRepository(string owner, string name); /// @@ -48,7 +45,6 @@ public interface IObservableEventsClient /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository /// /// The ID of the repository - /// All the s for the particular repository. IObservable GetAllForRepository(int repositoryId); /// @@ -60,7 +56,6 @@ public interface IObservableEventsClient /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository. IObservable GetAllForRepository(string owner, string name, ApiOptions options); /// @@ -71,7 +66,6 @@ public interface IObservableEventsClient /// /// The ID of the repository /// Options for changing the API response - /// All the s for the particular repository. IObservable GetAllForRepository(int repositoryId, ApiOptions options); /// @@ -82,7 +76,6 @@ public interface IObservableEventsClient /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository. IObservable GetAllIssuesForRepository(string owner, string name); /// @@ -92,7 +85,6 @@ public interface IObservableEventsClient /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository /// /// The ID of the repository - /// All the s for the particular repository. IObservable GetAllIssuesForRepository(int repositoryId); /// @@ -104,7 +96,6 @@ public interface IObservableEventsClient /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository. IObservable GetAllIssuesForRepository(string owner, string name, ApiOptions options); /// @@ -115,7 +106,6 @@ public interface IObservableEventsClient /// /// The ID of the repository /// Options for changing the API response - /// All the s for the particular repository. IObservable GetAllIssuesForRepository(int repositoryId, ApiOptions options); /// @@ -126,7 +116,6 @@ public interface IObservableEventsClient /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository network. IObservable GetAllForRepositoryNetwork(string owner, string name); /// @@ -138,7 +127,6 @@ public interface IObservableEventsClient /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository network. IObservable GetAllForRepositoryNetwork(string owner, string name, ApiOptions options); /// @@ -148,7 +136,6 @@ public interface IObservableEventsClient /// http://developer.github.com/v3/activity/events/#list-public-events-for-an-organization /// /// The name of the organization - /// All the s for the particular organization. IObservable GetAllForOrganization(string organization); /// @@ -159,7 +146,6 @@ public interface IObservableEventsClient /// /// The name of the organization /// Options for changing the API response - /// All the s for the particular organization. IObservable GetAllForOrganization(string organization, ApiOptions options); /// @@ -169,7 +155,6 @@ public interface IObservableEventsClient /// http://developer.github.com/v3/activity/events/#list-events-that-a-user-has-received /// /// The login of the user - /// All the s that a particular user has received. IObservable GetAllUserReceived(string user); /// @@ -180,7 +165,6 @@ public interface IObservableEventsClient /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has received. IObservable GetAllUserReceived(string user, ApiOptions options); /// @@ -190,7 +174,6 @@ public interface IObservableEventsClient /// http://developer.github.com/v3/activity/events/#list-public-events-that-a-user-has-received /// /// The login of the user - /// All the s that a particular user has received. IObservable GetAllUserReceivedPublic(string user); /// @@ -201,7 +184,6 @@ public interface IObservableEventsClient /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has received. IObservable GetAllUserReceivedPublic(string user, ApiOptions options); /// @@ -211,7 +193,6 @@ public interface IObservableEventsClient /// http://developer.github.com/v3/activity/events/#list-events-performed-by-a-user /// /// The login of the user - /// All the s that a particular user has performed. IObservable GetAllUserPerformed(string user); /// @@ -222,7 +203,6 @@ public interface IObservableEventsClient /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has performed. IObservable GetAllUserPerformed(string user, ApiOptions options); /// @@ -232,7 +212,6 @@ public interface IObservableEventsClient /// http://developer.github.com/v3/activity/events/#list-public-events-performed-by-a-user /// /// The login of the user - /// All the public s that a particular user has performed. IObservable GetAllUserPerformedPublic(string user); /// @@ -243,7 +222,6 @@ public interface IObservableEventsClient /// /// The login of the user /// Options for changing the API response - /// All the public s that a particular user has performed. IObservable GetAllUserPerformedPublic(string user, ApiOptions options); /// @@ -254,7 +232,6 @@ public interface IObservableEventsClient /// /// The login of the user /// The name of the organization - /// All the public s that are associated with an organization. IObservable GetAllForAnOrganization(string user, string organization); /// @@ -266,7 +243,6 @@ public interface IObservableEventsClient /// The login of the user /// The name of the organization /// Options for changing the API response - /// All the public s that are associated with an organization. IObservable GetAllForAnOrganization(string user, string organization, ApiOptions options); } } \ No newline at end of file diff --git a/Octokit.Reactive/Clients/ObservableEventsClient.cs b/Octokit.Reactive/Clients/ObservableEventsClient.cs index 318adce7df..dbfd2315cc 100644 --- a/Octokit.Reactive/Clients/ObservableEventsClient.cs +++ b/Octokit.Reactive/Clients/ObservableEventsClient.cs @@ -26,7 +26,6 @@ public ObservableEventsClient(IGitHubClient client) /// /// http://developer.github.com/v3/activity/events/#list-public-events /// - /// All the public s for the particular user. public IObservable GetAll() { return GetAll(ApiOptions.None); @@ -39,7 +38,6 @@ public IObservable GetAll() /// http://developer.github.com/v3/activity/events/#list-public-events /// /// Options for changing the API response - /// All the public s for the particular user. public IObservable GetAll(ApiOptions options) { Ensure.ArgumentNotNull(options, "options"); @@ -55,7 +53,6 @@ public IObservable GetAll(ApiOptions options) /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository. public IObservable GetAllForRepository(string owner, string name) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -71,7 +68,6 @@ public IObservable GetAllForRepository(string owner, string name) /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository /// /// The ID of the repository - /// All the s for the particular repository. public IObservable GetAllForRepository(int repositoryId) { return GetAllForRepository(repositoryId, ApiOptions.None); @@ -86,7 +82,6 @@ public IObservable GetAllForRepository(int repositoryId) /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository. public IObservable GetAllForRepository(string owner, string name, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -104,7 +99,6 @@ public IObservable GetAllForRepository(string owner, string name, ApiO /// /// The ID of the repository /// Options for changing the API response - /// All the s for the particular repository. public IObservable GetAllForRepository(int repositoryId, ApiOptions options) { Ensure.ArgumentNotNull(options, "options"); @@ -120,7 +114,6 @@ public IObservable GetAllForRepository(int repositoryId, ApiOptions op /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository. public IObservable GetAllIssuesForRepository(string owner, string name) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -136,7 +129,6 @@ public IObservable GetAllIssuesForRepository(string owner, string name /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository /// /// The ID of the repository - /// All the s for the particular repository. public IObservable GetAllIssuesForRepository(int repositoryId) { return GetAllIssuesForRepository(repositoryId, ApiOptions.None); @@ -151,7 +143,6 @@ public IObservable GetAllIssuesForRepository(int repositoryId) /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository. public IObservable GetAllIssuesForRepository(string owner, string name, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -169,7 +160,6 @@ public IObservable GetAllIssuesForRepository(string owner, string name /// /// The ID of the repository /// Options for changing the API response - /// All the s for the particular repository. public IObservable GetAllIssuesForRepository(int repositoryId, ApiOptions options) { Ensure.ArgumentNotNull(options, "options"); @@ -185,7 +175,6 @@ public IObservable GetAllIssuesForRepository(int repositoryId, ApiOpti /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository network. public IObservable GetAllForRepositoryNetwork(string owner, string name) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -203,7 +192,6 @@ public IObservable GetAllForRepositoryNetwork(string owner, string nam /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository network. public IObservable GetAllForRepositoryNetwork(string owner, string name, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -220,7 +208,6 @@ public IObservable GetAllForRepositoryNetwork(string owner, string nam /// http://developer.github.com/v3/activity/events/#list-public-events-for-an-organization /// /// The name of the organization - /// All the s for the particular organization. public IObservable GetAllForOrganization(string organization) { Ensure.ArgumentNotNullOrEmptyString(organization, "organization"); @@ -236,7 +223,6 @@ public IObservable GetAllForOrganization(string organization) /// /// The name of the organization /// Options for changing the API response - /// All the s for the particular organization. public IObservable GetAllForOrganization(string organization, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(organization, "organization"); @@ -252,7 +238,6 @@ public IObservable GetAllForOrganization(string organization, ApiOptio /// http://developer.github.com/v3/activity/events/#list-events-that-a-user-has-received /// /// The login of the user - /// All the s that a particular user has received. public IObservable GetAllUserReceived(string user) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -268,7 +253,6 @@ public IObservable GetAllUserReceived(string user) /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has received. public IObservable GetAllUserReceived(string user, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -284,7 +268,6 @@ public IObservable GetAllUserReceived(string user, ApiOptions options) /// http://developer.github.com/v3/activity/events/#list-public-events-that-a-user-has-received /// /// The login of the user - /// All the s that a particular user has received. public IObservable GetAllUserReceivedPublic(string user) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -300,7 +283,6 @@ public IObservable GetAllUserReceivedPublic(string user) /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has received. public IObservable GetAllUserReceivedPublic(string user, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -316,7 +298,6 @@ public IObservable GetAllUserReceivedPublic(string user, ApiOptions op /// http://developer.github.com/v3/activity/events/#list-events-performed-by-a-user /// /// The login of the user - /// All the s that a particular user has performed. public IObservable GetAllUserPerformed(string user) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -332,7 +313,6 @@ public IObservable GetAllUserPerformed(string user) /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has performed. public IObservable GetAllUserPerformed(string user, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -348,7 +328,6 @@ public IObservable GetAllUserPerformed(string user, ApiOptions options /// http://developer.github.com/v3/activity/events/#list-public-events-performed-by-a-user /// /// The login of the user - /// All the public s that a particular user has performed. public IObservable GetAllUserPerformedPublic(string user) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -364,7 +343,6 @@ public IObservable GetAllUserPerformedPublic(string user) /// /// The login of the user /// Options for changing the API response - /// All the public s that a particular user has performed. public IObservable GetAllUserPerformedPublic(string user, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -381,7 +359,6 @@ public IObservable GetAllUserPerformedPublic(string user, ApiOptions o /// /// The login of the user /// The name of the organization - /// All the public s that are associated with an organization. public IObservable GetAllForAnOrganization(string user, string organization) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -399,7 +376,6 @@ public IObservable GetAllForAnOrganization(string user, string organiz /// The login of the user /// The name of the organization /// Options for changing the API response - /// All the public s that are associated with an organization. public IObservable GetAllForAnOrganization(string user, string organization, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); diff --git a/Octokit/Clients/EventsClient.cs b/Octokit/Clients/EventsClient.cs index d6c9147428..a4b2382cee 100644 --- a/Octokit/Clients/EventsClient.cs +++ b/Octokit/Clients/EventsClient.cs @@ -26,7 +26,6 @@ public EventsClient(IApiConnection apiConnection) /// /// http://developer.github.com/v3/activity/events/#list-public-events /// - /// All the public s for the particular user. public Task> GetAll() { return GetAll(ApiOptions.None); @@ -55,7 +54,6 @@ public Task> GetAll(ApiOptions options) /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository. public Task> GetAllForRepository(string owner, string name) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -71,7 +69,6 @@ public Task> GetAllForRepository(string owner, string na /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository /// /// The ID of the repository - /// All the s for the particular repository. public Task> GetAllForRepository(int repositoryId) { return GetAllForRepository(repositoryId, ApiOptions.None); @@ -86,7 +83,6 @@ public Task> GetAllForRepository(int repositoryId) /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository. public Task> GetAllForRepository(string owner, string name, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -104,7 +100,6 @@ public Task> GetAllForRepository(string owner, string na /// /// The ID of the repository /// Options for changing the API response - /// All the s for the particular repository. public Task> GetAllForRepository(int repositoryId, ApiOptions options) { Ensure.ArgumentNotNull(options, "options"); @@ -120,7 +115,6 @@ public Task> GetAllForRepository(int repositoryId, ApiOp /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository. public Task> GetAllIssuesForRepository(string owner, string name) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -136,7 +130,6 @@ public Task> GetAllIssuesForRepository(string owner, str /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository /// /// The ID of the repository - /// All the s for the particular repository. public Task> GetAllIssuesForRepository(int repositoryId) { return GetAllIssuesForRepository(repositoryId, ApiOptions.None); @@ -151,7 +144,6 @@ public Task> GetAllIssuesForRepository(int repositoryId) /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository. public Task> GetAllIssuesForRepository(string owner, string name, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -169,7 +161,6 @@ public Task> GetAllIssuesForRepository(string owner, str /// /// The ID of the repository /// Options for changing the API response - /// All the s for the particular repository. public Task> GetAllIssuesForRepository(int repositoryId, ApiOptions options) { Ensure.ArgumentNotNull(options, "options"); @@ -185,7 +176,6 @@ public Task> GetAllIssuesForRepository(int repositoryId, /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository network. public Task> GetAllForRepositoryNetwork(string owner, string name) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -203,7 +193,6 @@ public Task> GetAllForRepositoryNetwork(string owner, st /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository network. public Task> GetAllForRepositoryNetwork(string owner, string name, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); @@ -220,7 +209,6 @@ public Task> GetAllForRepositoryNetwork(string owner, st /// http://developer.github.com/v3/activity/events/#list-public-events-for-an-organization /// /// The name of the organization - /// All the s for the particular organization. public Task> GetAllForOrganization(string organization) { Ensure.ArgumentNotNullOrEmptyString(organization, "organization"); @@ -236,7 +224,6 @@ public Task> GetAllForOrganization(string organization) /// /// The name of the organization /// Options for changing the API response - /// All the s for the particular organization. public Task> GetAllForOrganization(string organization, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(organization, "organization"); @@ -252,7 +239,6 @@ public Task> GetAllForOrganization(string organization, /// http://developer.github.com/v3/activity/events/#list-events-that-a-user-has-received /// /// The login of the user - /// All the s that a particular user has received. public Task> GetAllUserReceived(string user) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -268,7 +254,6 @@ public Task> GetAllUserReceived(string user) /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has received. public Task> GetAllUserReceived(string user, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -284,7 +269,6 @@ public Task> GetAllUserReceived(string user, ApiOptions /// http://developer.github.com/v3/activity/events/#list-public-events-that-a-user-has-received /// /// The login of the user - /// All the s that a particular user has received. public Task> GetAllUserReceivedPublic(string user) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -300,7 +284,6 @@ public Task> GetAllUserReceivedPublic(string user) /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has received. public Task> GetAllUserReceivedPublic(string user, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -316,7 +299,6 @@ public Task> GetAllUserReceivedPublic(string user, ApiOp /// http://developer.github.com/v3/activity/events/#list-events-performed-by-a-user /// /// The login of the user - /// All the s that a particular user has performed. public Task> GetAllUserPerformed(string user) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -332,7 +314,6 @@ public Task> GetAllUserPerformed(string user) /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has performed. public Task> GetAllUserPerformed(string user, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -348,7 +329,6 @@ public Task> GetAllUserPerformed(string user, ApiOptions /// http://developer.github.com/v3/activity/events/#list-public-events-performed-by-a-user /// /// The login of the user - /// All the public s that a particular user has performed. public Task> GetAllUserPerformedPublic(string user) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -364,7 +344,6 @@ public Task> GetAllUserPerformedPublic(string user) /// /// The login of the user /// Options for changing the API response - /// All the public s that a particular user has performed. public Task> GetAllUserPerformedPublic(string user, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -381,7 +360,6 @@ public Task> GetAllUserPerformedPublic(string user, ApiO /// /// The login of the user /// The name of the organization - /// All the public s that are associated with an organization. public Task> GetAllForAnOrganization(string user, string organization) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); @@ -399,7 +377,6 @@ public Task> GetAllForAnOrganization(string user, string /// The login of the user /// The name of the organization /// Options for changing the API response - /// All the public s that are associated with an organization. public Task> GetAllForAnOrganization(string user, string organization, ApiOptions options) { Ensure.ArgumentNotNullOrEmptyString(user, "user"); diff --git a/Octokit/Clients/IEventsClient.cs b/Octokit/Clients/IEventsClient.cs index 679fb16d5c..3c2d0325a0 100644 --- a/Octokit/Clients/IEventsClient.cs +++ b/Octokit/Clients/IEventsClient.cs @@ -17,7 +17,6 @@ public interface IEventsClient /// /// http://developer.github.com/v3/activity/events/#list-public-events /// - /// All the public s for the particular user. [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")] Task> GetAll(); @@ -39,7 +38,6 @@ public interface IEventsClient /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository. Task> GetAllForRepository(string owner, string name); /// @@ -49,7 +47,6 @@ public interface IEventsClient /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository /// /// The ID of the repository - /// All the s for the particular repository. Task> GetAllForRepository(int repositoryId); /// @@ -61,7 +58,6 @@ public interface IEventsClient /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository. Task> GetAllForRepository(string owner, string name, ApiOptions options); /// @@ -72,7 +68,6 @@ public interface IEventsClient /// /// The ID of the repository /// Options for changing the API response - /// All the s for the particular repository. Task> GetAllForRepository(int repositoryId, ApiOptions options); /// @@ -83,7 +78,6 @@ public interface IEventsClient /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository. Task> GetAllIssuesForRepository(string owner, string name); /// @@ -93,7 +87,6 @@ public interface IEventsClient /// http://developer.github.com/v3/activity/events/#list-issue-events-for-a-repository /// /// The ID of the repository - /// All the s for the particular repository. Task> GetAllIssuesForRepository(int repositoryId); /// @@ -105,7 +98,6 @@ public interface IEventsClient /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository. Task> GetAllIssuesForRepository(string owner, string name, ApiOptions options); /// @@ -116,7 +108,6 @@ public interface IEventsClient /// /// The ID of the repository /// Options for changing the API response - /// All the s for the particular repository. Task> GetAllIssuesForRepository(int repositoryId, ApiOptions options); /// @@ -127,7 +118,6 @@ public interface IEventsClient /// /// The owner of the repository /// The name of the repository - /// All the s for the particular repository network. Task> GetAllForRepositoryNetwork(string owner, string name); /// @@ -139,7 +129,6 @@ public interface IEventsClient /// The owner of the repository /// The name of the repository /// Options for changing the API response - /// All the s for the particular repository network. Task> GetAllForRepositoryNetwork(string owner, string name, ApiOptions options); /// @@ -149,7 +138,6 @@ public interface IEventsClient /// http://developer.github.com/v3/activity/events/#list-public-events-for-an-organization /// /// The name of the organization - /// All the s for the particular organization. Task> GetAllForOrganization(string organization); /// @@ -160,7 +148,6 @@ public interface IEventsClient /// /// The name of the organization /// Options for changing the API response - /// All the s for the particular organization. Task> GetAllForOrganization(string organization, ApiOptions options); /// @@ -170,7 +157,6 @@ public interface IEventsClient /// http://developer.github.com/v3/activity/events/#list-events-that-a-user-has-received /// /// The login of the user - /// All the s that a particular user has received. Task> GetAllUserReceived(string user); /// @@ -181,7 +167,6 @@ public interface IEventsClient /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has received. Task> GetAllUserReceived(string user, ApiOptions options); /// @@ -191,7 +176,6 @@ public interface IEventsClient /// http://developer.github.com/v3/activity/events/#list-public-events-that-a-user-has-received /// /// The login of the user - /// All the s that a particular user has received. Task> GetAllUserReceivedPublic(string user); /// @@ -202,7 +186,6 @@ public interface IEventsClient /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has received. Task> GetAllUserReceivedPublic(string user, ApiOptions options); /// @@ -212,7 +195,6 @@ public interface IEventsClient /// http://developer.github.com/v3/activity/events/#list-events-performed-by-a-user /// /// The login of the user - /// All the s that a particular user has performed. Task> GetAllUserPerformed(string user); /// @@ -223,7 +205,6 @@ public interface IEventsClient /// /// The login of the user /// Options for changing the API response - /// All the s that a particular user has performed. Task> GetAllUserPerformed(string user, ApiOptions options); /// @@ -233,7 +214,6 @@ public interface IEventsClient /// http://developer.github.com/v3/activity/events/#list-public-events-performed-by-a-user /// /// The login of the user - /// All the public s that a particular user has performed. Task> GetAllUserPerformedPublic(string user); /// @@ -244,7 +224,6 @@ public interface IEventsClient /// /// The login of the user /// Options for changing the API response - /// All the public s that a particular user has performed. Task> GetAllUserPerformedPublic(string user, ApiOptions options); /// @@ -255,7 +234,6 @@ public interface IEventsClient /// /// The login of the user /// The name of the organization - /// All the public s that are associated with an organization. Task> GetAllForAnOrganization(string user, string organization); /// @@ -267,7 +245,6 @@ public interface IEventsClient /// The login of the user /// The name of the organization /// Options for changing the API response - /// All the public s that are associated with an organization. Task> GetAllForAnOrganization(string user, string organization, ApiOptions options); } } \ No newline at end of file