use a uint8 to represent the key phase bit

This commit is contained in:
Marten Seemann
2020-10-06 15:25:31 +07:00
parent 93e3873141
commit d5a30225ce
4 changed files with 29 additions and 19 deletions

View File

@@ -6,6 +6,11 @@ import (
)
var _ = Describe("Key Phases", func() {
It("has undefined as its default value", func() {
var k KeyPhaseBit
Expect(k).To(Equal(KeyPhaseUndefined))
})
It("has the correct string representation", func() {
Expect(KeyPhaseZero.String()).To(Equal("0"))
Expect(KeyPhaseOne.String()).To(Equal("1"))