Change the QueueLdapSync calls to use Post<T>(uri) with no body/data

This commit is contained in:
Ryan Gribble
2016-02-06 22:41:17 +10:00
parent 6965ac44b2
commit 1f13001fd8
22 changed files with 165 additions and 60 deletions
@@ -0,0 +1,28 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Octokit.Tests.Integration.Helpers
{
internal sealed class EnterpriseTeamContext : IDisposable
{
internal EnterpriseTeamContext(Team team)
{
Team = team;
TeamId = team.Id;
TeamName = team.Name;
}
internal int TeamId { get; private set; }
internal string TeamName { get; private set; }
internal Team Team { get; private set; }
public void Dispose()
{
EnterpriseHelper.DeleteTeam(Team);
}
}
}
@@ -29,5 +29,12 @@ namespace Octokit.Tests.Integration.Helpers
return new RepositoryContext(repo);
}
internal async static Task<EnterpriseTeamContext> CreateEnterpriseTeamContext(this IGitHubClient client, string organization, NewTeam newTeam)
{
var team = await client.Organization.Team.Create(organization, newTeam);
return new EnterpriseTeamContext(team);
}
}
}