shithub: furgit

Download patch

ref: 74b7854daa573894c8e725717567915bf55b22a0
parent: fe595229e41f9aea5c08d5ab3889804b77a70359
author: Runxi Yu <me@runxiyu.org>
date: Fri Feb 20 19:23:57 EST 2026

testgit: Use objectid's SupportedAlgorithms

--- a/internal/testgit/algorithms.go
+++ b/internal/testgit/algorithms.go
@@ -6,18 +6,10 @@
 	"codeberg.org/lindenii/furgit/objectid"
 )
 
-// SupportedAlgorithms returns all object ID algorithms supported by furgit.
-func SupportedAlgorithms() []objectid.Algorithm {
-	return []objectid.Algorithm{
-		objectid.AlgorithmSHA1,
-		objectid.AlgorithmSHA256,
-	}
-}
-
 // ForEachAlgorithm runs a subtest for every supported algorithm.
 func ForEachAlgorithm(t *testing.T, fn func(t *testing.T, algo objectid.Algorithm)) {
 	t.Helper()
-	for _, algo := range SupportedAlgorithms() {
+	for _, algo := range objectid.SupportedAlgorithms() {
 		t.Run(algo.String(), func(t *testing.T) {
 			fn(t, algo)
 		})
--