fix: replace string(rune()) with strconv.Itoa in tests (bd-fmc)
Also updated CONFIG.md to clarify mass delete threshold requires >5 issues (bd-in6).
The string(rune('0'+i)) pattern produces incorrect characters when i >= 10.
Changed to strconv.Itoa(i) for reliable conversion.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -4,6 +4,7 @@ package sqlite
|
||||
|
||||
import (
|
||||
"context"
|
||||
"strconv"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
@@ -112,9 +113,9 @@ func BenchmarkCheckEligibility(b *testing.B) {
|
||||
}
|
||||
}
|
||||
|
||||
func generateID(b testing.TB, prefix string, n int) string{
|
||||
func generateID(b testing.TB, prefix string, n int) string {
|
||||
b.Helper()
|
||||
return prefix + string(rune('0'+n/10)) + string(rune('0'+n%10))
|
||||
return prefix + strconv.Itoa(n)
|
||||
}
|
||||
|
||||
func setupBenchDB(tb testing.TB) (*SQLiteStorage, func()) {
|
||||
|
||||
Reference in New Issue
Block a user