mirror of
				https://github.com/go-gitea/gitea.git
				synced 2025-11-04 11:01:32 +00:00 
			
		
		
		
	Backport #35056
This commit is contained in:
		@@ -82,7 +82,7 @@ func testGetCommitsInfo(t *testing.T, repo1 *Repository) {
 | 
			
		||||
		}
 | 
			
		||||
 | 
			
		||||
		// FIXME: Context.TODO() - if graceful has started we should use its Shutdown context otherwise use install signals in TestMain.
 | 
			
		||||
		commitsInfo, treeCommit, err := entries.GetCommitsInfo(t.Context(), commit, testCase.Path)
 | 
			
		||||
		commitsInfo, treeCommit, err := entries.GetCommitsInfo(t.Context(), "/any/repo-link", commit, testCase.Path)
 | 
			
		||||
		assert.NoError(t, err, "Unable to get commit information for entries of subtree: %s in commit: %s from testcase due to error: %v", testCase.Path, testCase.CommitID, err)
 | 
			
		||||
		if err != nil {
 | 
			
		||||
			t.FailNow()
 | 
			
		||||
@@ -159,7 +159,7 @@ func BenchmarkEntries_GetCommitsInfo(b *testing.B) {
 | 
			
		||||
		b.ResetTimer()
 | 
			
		||||
		b.Run(benchmark.name, func(b *testing.B) {
 | 
			
		||||
			for b.Loop() {
 | 
			
		||||
				_, _, err := entries.GetCommitsInfo(b.Context(), commit, "")
 | 
			
		||||
				_, _, err := entries.GetCommitsInfo(b.Context(), "/any/repo-link", commit, "")
 | 
			
		||||
				if err != nil {
 | 
			
		||||
					b.Fatal(err)
 | 
			
		||||
				}
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user