public Update ( string organizationName, OrganizationUpdate updateRequest ) : IObservable |
||
organizationName | string | The name of the organization to update. |
updateRequest | OrganizationUpdate | |
return | IObservable |
public void EnsuresNonNullArguments() { var gitHubClient = Substitute.For<IGitHubClient>(); var client = new ObservableOrganizationsClient(gitHubClient); Assert.Throws<ArgumentNullException>(() => client.Update(null, new OrganizationUpdate())); Assert.Throws<ArgumentNullException>(() => client.Update("org", null)); Assert.Throws<ArgumentException>(() => client.Update("", new OrganizationUpdate())); }
public void RequestsTheCorrectUrl() { var gitHubClient = Substitute.For<IGitHubClient>(); var client = new ObservableOrganizationsClient(gitHubClient); var organizationUpdate = new OrganizationUpdate(); client.Update("initrode", organizationUpdate); gitHubClient.Received().Organization.Update("initrode", organizationUpdate); }