uquic/internal/wire/ack_range_test.go
Marten Seemann 5c98332e90 implement ACK decimation
ACK generation closely follows Chrome's QuicConnection::MaybeQueueAck()
in ACK_DECIMATION_WITH_REORDERING mode.
2018-03-05 19:56:19 +07:00

13 lines
299 B
Go

package wire
import (
. "github.com/onsi/ginkgo"
. "github.com/onsi/gomega"
)
var _ = Describe("ACK range", func() {
It("returns the length", func() {
Expect(AckRange{First: 10, Last: 10}.Len()).To(BeEquivalentTo(1))
Expect(AckRange{First: 10, Last: 13}.Len()).To(BeEquivalentTo(4))
})
})