Verify performs integrity checks on the node set.
()
| 119 | |
| 120 | // Verify performs integrity checks on the node set. |
| 121 | func (ns NodeSet) Verify() error { |
| 122 | for id, n := range ns { |
| 123 | if n.N.ID() != id { |
| 124 | return fmt.Errorf("invalid node %v: ID does not match ID %v in record", id, n.N.ID()) |
| 125 | } |
| 126 | if n.N.Seq() != n.Seq { |
| 127 | return fmt.Errorf("invalid node %v: 'seq' does not match seq %d from record", id, n.N.Seq()) |
| 128 | } |
| 129 | } |
| 130 | return nil |
| 131 | } |
nothing calls this directly
no outgoing calls
no test coverage detected