github.com/apernet/quic-go@v0.43.1-0.20240515053213-5e9e635fd9f0/internal/wire/handshake_done_frame_test.go (about) 1 package wire 2 3 import ( 4 "github.com/apernet/quic-go/internal/protocol" 5 6 . "github.com/onsi/ginkgo/v2" 7 . "github.com/onsi/gomega" 8 ) 9 10 var _ = Describe("HANDSHAKE_DONE frame", func() { 11 Context("when writing", func() { 12 It("writes a sample frame", func() { 13 frame := HandshakeDoneFrame{} 14 b, err := frame.Append(nil, protocol.Version1) 15 Expect(err).ToNot(HaveOccurred()) 16 Expect(b).To(Equal([]byte{handshakeDoneFrameType})) 17 }) 18 19 It("has the correct min length", func() { 20 frame := HandshakeDoneFrame{} 21 Expect(frame.Length(protocol.Version1)).To(Equal(protocol.ByteCount(1))) 22 }) 23 }) 24 })