package services import "testing" func BenchmarkPasswordVerification(b *testing.B) { const password = "synthetic-benchmark-password" hash, err := HashPassword(password) if err != nil { b.Fatal(err) } b.ReportAllocs() b.ResetTimer() for i := 0; i < b.N; i++ { ok, err := VerifyPassword(password, hash) if err != nil || !ok { b.Fatalf("verification failed: %v", err) } } }