diff --git a/Octokit.Reactive/Clients/IObservableUserKeysClient.cs b/Octokit.Reactive/Clients/IObservableUserKeysClient.cs
index bf196a00fb..4c5aa92728 100644
--- a/Octokit.Reactive/Clients/IObservableUserKeysClient.cs
+++ b/Octokit.Reactive/Clients/IObservableUserKeysClient.cs
@@ -19,7 +19,8 @@ public interface IObservableUserKeysClient
/// https://developer.github.com/v3/users/keys/#list-your-public-keys
///
///
- IObservable GetAll();
+ [SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")]
+ IObservable GetAllForCurrent();
///
/// Gets all verified public keys for a user.
diff --git a/Octokit.Reactive/Clients/ObservableUserKeysClient.cs b/Octokit.Reactive/Clients/ObservableUserKeysClient.cs
index 15245375c9..1b563b94ad 100644
--- a/Octokit.Reactive/Clients/ObservableUserKeysClient.cs
+++ b/Octokit.Reactive/Clients/ObservableUserKeysClient.cs
@@ -29,9 +29,9 @@ public ObservableUserKeysClient(IGitHubClient client)
/// https://developer.github.com/v3/users/keys/#list-your-public-keys
///
///
- public IObservable GetAll()
+ public IObservable GetAllForCurrent()
{
- return _client.GetAll().ToObservable().SelectMany(k => k);
+ return _client.GetAllForCurrent().ToObservable().SelectMany(k => k);
}
///
diff --git a/Octokit.Tests.Integration/Clients/UserKeysClientTests.cs b/Octokit.Tests.Integration/Clients/UserKeysClientTests.cs
index 29d3d90d92..8a71120627 100644
--- a/Octokit.Tests.Integration/Clients/UserKeysClientTests.cs
+++ b/Octokit.Tests.Integration/Clients/UserKeysClientTests.cs
@@ -14,7 +14,7 @@ public async Task CanGetAllForCurrentUser()
using (var context = await github.CreatePublicKeyContext())
{
- var keys = await github.User.Keys.GetAll();
+ var keys = await github.User.Keys.GetAllForCurrent();
Assert.NotEmpty(keys);
var first = keys[0];
@@ -72,7 +72,7 @@ public async Task CanCreateAndDeleteKey()
await github.User.Keys.Delete(key.Id);
// Verify key no longer exists
- var keys = await github.User.Keys.GetAll();
+ var keys = await github.User.Keys.GetAllForCurrent();
Assert.False(keys.Any(k => k.Title == keyTitle && k.Key == keyData));
}
}
diff --git a/Octokit.Tests.Integration/Reactive/ObservableUserKeysClientTests.cs b/Octokit.Tests.Integration/Reactive/ObservableUserKeysClientTests.cs
index 4dc157281d..cf56317b7b 100644
--- a/Octokit.Tests.Integration/Reactive/ObservableUserKeysClientTests.cs
+++ b/Octokit.Tests.Integration/Reactive/ObservableUserKeysClientTests.cs
@@ -21,7 +21,7 @@ public async Task CanGetAllForCurrentUser()
{
using (var context = await _github.CreatePublicKeyContext())
{
- var observable = _github.User.Keys.GetAll();
+ var observable = _github.User.Keys.GetAllForCurrent();
var keys = await (observable.ToList());
Assert.NotEmpty(keys);
@@ -80,7 +80,7 @@ public async Task CanCreateAndDeleteKey()
await _github.User.Keys.Delete(key.Id);
// Verify key no longer exists
- var keys = await (_github.User.Keys.GetAll().ToList());
+ var keys = await (_github.User.Keys.GetAllForCurrent().ToList());
Assert.False(keys.Any(k => k.Title == keyTitle && k.Key == keyData));
}
}
diff --git a/Octokit.Tests/Clients/UserKeysClientTests.cs b/Octokit.Tests/Clients/UserKeysClientTests.cs
index 90d60f1d8d..e36369f073 100644
--- a/Octokit.Tests/Clients/UserKeysClientTests.cs
+++ b/Octokit.Tests/Clients/UserKeysClientTests.cs
@@ -8,7 +8,7 @@ namespace Octokit.Tests.Clients
{
public class UserKeysClientTests
{
- public class TheGetAllMethod
+ public class TheGetAllForCurrentMethod
{
[Fact]
public void RequestsTheCorrectUrl()
@@ -17,7 +17,7 @@ public void RequestsTheCorrectUrl()
var client = new UserKeysClient(connection);
var expectedUri = "user/keys";
- client.GetAll();
+ client.GetAllForCurrent();
connection.Received().GetAll(
Arg.Is(u => u.ToString() == expectedUri));
diff --git a/Octokit.Tests/Reactive/ObservableUserKeysClientTests.cs b/Octokit.Tests/Reactive/ObservableUserKeysClientTests.cs
index 508e129a8b..3a569e27a9 100644
--- a/Octokit.Tests/Reactive/ObservableUserKeysClientTests.cs
+++ b/Octokit.Tests/Reactive/ObservableUserKeysClientTests.cs
@@ -8,7 +8,7 @@ namespace Octokit.Tests.Reactive
{
public class ObservableUserKeysClientTests
{
- public class TheGetAllMethod
+ public class TheGetAllForCurrentMethod
{
[Fact]
public void CallsIntoClient()
@@ -16,9 +16,9 @@ public void CallsIntoClient()
var gitHubClient = Substitute.For();
var client = new ObservableUserKeysClient(gitHubClient);
- client.GetAll();
+ client.GetAllForCurrent();
- gitHubClient.User.Keys.Received().GetAll();
+ gitHubClient.User.Keys.Received().GetAllForCurrent();
}
}
diff --git a/Octokit/Clients/IUserKeysClient.cs b/Octokit/Clients/IUserKeysClient.cs
index 226778b681..41b5a76b90 100644
--- a/Octokit/Clients/IUserKeysClient.cs
+++ b/Octokit/Clients/IUserKeysClient.cs
@@ -19,7 +19,8 @@ public interface IUserKeysClient
/// https://developer.github.com/v3/users/keys/#list-your-public-keys
///
///
- Task> GetAll();
+ [SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")]
+ Task> GetAllForCurrent();
///
/// Gets all verified public keys for a user.
diff --git a/Octokit/Clients/UserKeysClient.cs b/Octokit/Clients/UserKeysClient.cs
index 012b32ae30..cc8dee50b8 100644
--- a/Octokit/Clients/UserKeysClient.cs
+++ b/Octokit/Clients/UserKeysClient.cs
@@ -23,7 +23,7 @@ public UserKeysClient(IApiConnection apiConnection)
/// https://developer.github.com/v3/users/keys/#list-your-public-keys
///
///
- public Task> GetAll()
+ public Task> GetAllForCurrent()
{
return ApiConnection.GetAll(ApiUrls.Keys());
}