(test *testing.T)
| 104 | } |
| 105 | |
| 106 | func TestPublicRecovery(test *testing.T) { |
| 107 | n := 10 |
| 108 | t := n/2 + 1 |
| 109 | |
| 110 | priPoly := NewPriPoly(suite, t, nil, suite.RandomStream()) |
| 111 | pubPoly := priPoly.Commit(nil) |
| 112 | pubShares := pubPoly.Shares(n) |
| 113 | |
| 114 | recovered, err := RecoverCommit(suite, pubShares, t, n) |
| 115 | if err != nil { |
| 116 | test.Fatal(err) |
| 117 | } |
| 118 | |
| 119 | if !recovered.Equal(pubPoly.Commit()) { |
| 120 | test.Fatal("recovered commit does not match initial value") |
| 121 | } |
| 122 | } |
| 123 | |
| 124 | func TestPublicRecoveryDelete(test *testing.T) { |
| 125 | n := 10 |
nothing calls this directly
no test coverage detected