mirror of
https://github.com/zoriya/octokit.net.git
synced 2026-06-03 19:11:30 +00:00
Implement Nested Teams preview API changes (#1682)
* Add new AcceptsHeader add Parent field to Team add ParentId field to NewTeam and UpdateTeam update Create Edit and Delete Team methods to use preview header * Implement new API call GetAllChildTeams() * Implement GetAllChildTeams for ObservableClient * add integration test for observable client * Add pagination tests for GetAllChildTeams * Add NestedTeams preview header to all the API calls that use it * Update tests for accepts header * Add accepts header to observable client calls * Fix DELETE implementation to use correct overload * Fix tests - parent and child teams must be visibility Closed whereas the default if not specified is Private * make sure all tests are flagged as [OrganizationTest] * Make sure Update tests change the parent of the team * Update new methods with NesterTeams preview API header and adjust tests
This commit is contained in:
@@ -30,6 +30,7 @@ namespace Octokit.Tests.Integration.Helpers
|
||||
|
||||
internal static async Task<TeamContext> CreateTeamContext(this IObservableGitHubClient client, string organization, NewTeam newTeam)
|
||||
{
|
||||
newTeam.Privacy = TeamPrivacy.Closed;
|
||||
var team = await client.Organization.Team.Create(organization, newTeam);
|
||||
|
||||
return new TeamContext(client.Connection, team);
|
||||
|
||||
Reference in New Issue
Block a user