introduce PacketNumberLen type

This commit is contained in:
Marten Seemann
2016-05-09 17:31:12 +07:00
parent a141c31c69
commit e8ba73f275
19 changed files with 61 additions and 46 deletions

View File

@@ -22,7 +22,7 @@ var _ = Describe("BlockedFrame", func() {
It("writes a sample frame", func() {
b := &bytes.Buffer{}
frame := BlockedFrame{StreamID: 0x1337}
frame.Write(b, 10, 6)
frame.Write(b, 10, protocol.PacketNumberLen6)
Expect(b.Bytes()).To(Equal([]byte{0x05, 0x37, 0x13, 0x0, 0x0}))
})