MCPcopy Index your code
hub / github.com/coder/coder / FuzzGenerateDeterministicKey

Function FuzzGenerateDeterministicKey

agent/agentrsa/key_test.go:40–51  ·  view source on GitHub ↗
(f *testing.F)

Source from the content-addressed store, hash-verified

38}
39
40func FuzzGenerateDeterministicKey(f *testing.F) {
41 testcases := []int64{0, 1234, 1010101010}
42 for _, tc := range testcases {
43 f.Add(tc) // Use f.Add to provide a seed corpus
44 }
45 f.Fuzz(func(t *testing.T, seed int64) {
46 key1 := agentrsa.GenerateDeterministicKey(seed)
47 key2 := agentrsa.GenerateDeterministicKey(seed)
48 assert.Equal(t, key1, key2)
49 assert.EqualExportedValues(t, key1, key2)
50 })
51}

Callers

nothing calls this directly

Calls 3

GenerateDeterministicKeyFunction · 0.92
AddMethod · 0.65
EqualMethod · 0.45

Tested by

no test coverage detected