remove this repository cleanup code

This commit is contained in:
Brendan Forster
2015-01-02 15:57:07 +09:30
parent 8f0d55bc03
commit 70c22f98ff
@@ -9,7 +9,7 @@ using Octokit.Tests.Helpers;
public class RepositoriesClientTests
{
public class TheCreateMethodForUser : IDisposable
public class TheCreateMethodForUser
{
[IntegrationTest]
public async Task CreatesANewPublicRepository()
@@ -330,37 +330,6 @@ public class RepositoriesClientTests
Task.WhenAll(deleteRepos).Wait();
}
}
public void Dispose()
{
var github = new GitHubClient(new ProductHeaderValue("OctokitTests"))
{
Credentials = Helper.Credentials
};
try
{
// clean all the repositories for the current user
var repositories = github.Repository.GetAllForCurrent().Result;
foreach (var repository in repositories.Where(x => x.Owner.Login == Helper.Credentials.Login))
{
try
{
// only cleanup repositories the current user owns
github.Repository.Delete(repository.Owner.Login, repository.Name).Wait();
}
catch (Exception)
{
}
}
}
catch (Exception ex)
{
Console.WriteLine("An unexpected exception occurred while retrieving repositories for the current user: " + ex);
}
}
}
public class TheCreateMethodForOrganization