(t *testing.T)
| 56 | } |
| 57 | |
| 58 | func TestGoodBlockHeaderBytes(t *testing.T) { |
| 59 | goodBlockHeader := &cb.BlockHeader{ |
| 60 | Number: 1, |
| 61 | PreviousHash: []byte("foo"), |
| 62 | DataHash: []byte("bar"), |
| 63 | } |
| 64 | |
| 65 | _ = protoutil.BlockHeaderBytes(goodBlockHeader) // Should not panic |
| 66 | |
| 67 | goodBlockHeaderMaxNumber := &cb.BlockHeader{ |
| 68 | Number: math.MaxUint64, |
| 69 | PreviousHash: []byte("foo"), |
| 70 | DataHash: []byte("bar"), |
| 71 | } |
| 72 | |
| 73 | _ = protoutil.BlockHeaderBytes(goodBlockHeaderMaxNumber) // Should not panic |
| 74 | } |
| 75 | |
| 76 | func TestGetChannelIDFromBlockBytes(t *testing.T) { |
| 77 | gb, err := configtxtest.MakeGenesisBlock(testChannelID) |
nothing calls this directly
no test coverage detected