mirror of
https://github.com/burrowers/garble.git
synced 2025-12-24 12:58:05 +08:00
fix fuzz_test.go
This commit is contained in:
@@ -72,7 +72,9 @@ func FuzzObfuscate(f *testing.F) {
|
||||
|
||||
// Obfuscate the literals and print the source back.
|
||||
rand := mathrand.New(mathrand.NewSource(randSeed))
|
||||
srcSyntax = literals.Obfuscate(rand, srcSyntax, &info, nil)
|
||||
srcSyntax = literals.Obfuscate(rand, srcSyntax, &info, nil, func(rand *mathrand.Rand, baseName string) string {
|
||||
return fmt.Sprintf("%s%d", baseName, rand.Uint64())
|
||||
})
|
||||
count := tdirCounter.Add(1)
|
||||
f, err := os.Create(filepath.Join(tdir, fmt.Sprintf("src_%d.go", count)))
|
||||
qt.Assert(t, qt.IsNil(err))
|
||||
|
||||
Reference in New Issue
Block a user