MCPcopy Create free account
hub / github.com/DNAProject/DNA / TestCalcParticipantPeers

Function TestCalcParticipantPeers

consensus/vbft/node_utils_test.go:167–178  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

165}
166
167func TestCalcParticipantPeers(t *testing.T) {
168 for i := 4; i < 100; i++ {
169 testCalcParticipantPeers(t, i, (i-1)/3)
170 }
171 for i := 5; i < 100; i++ {
172 testCalcParticipantPeers(t, i, (i-1)/4)
173 }
174 for i := 0; i < 10000; i++ {
175 testCalcParticipantPeers(t, 7, 2)
176 testCalcParticipantPeers(t, 4, 1)
177 }
178}
179
180func testCalcParticipantPeers(t *testing.T, n, c int) {
181 server := constructServer()

Callers

nothing calls this directly

Calls 1

testCalcParticipantPeersFunction · 0.85

Tested by

no test coverage detected