summaryrefslogtreecommitdiffstats
path: root/integrations/api_repo_get_contents_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'integrations/api_repo_get_contents_test.go')
-rw-r--r--integrations/api_repo_get_contents_test.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/integrations/api_repo_get_contents_test.go b/integrations/api_repo_get_contents_test.go
index f6a43bc5c6..77a827ec61 100644
--- a/integrations/api_repo_get_contents_test.go
+++ b/integrations/api_repo_get_contents_test.go
@@ -75,6 +75,8 @@ func testAPIGetContents(t *testing.T, u *url.URL) {
repo1.CreateNewBranch(user2, repo1.DefaultBranch, newBranch)
// Get the commit ID of the default branch
gitRepo, _ := git.OpenRepository(repo1.RepoPath())
+ defer gitRepo.Close()
+
commitID, _ := gitRepo.GetBranchCommitID(repo1.DefaultBranch)
// Make a new tag in repo1
newTag := "test_tag"