MCPcopy Create free account
hub / github.com/boombuler/barcode / TestBinaryEncoder

Function TestBinaryEncoder

pdf417/highlevel_test.go:33–41  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

31}
32
33func TestBinaryEncoder(t *testing.T) {
34 runTest := func(msg string, expected ...int) {
35 codes := encodeBinary([]byte(msg), encText)
36 compareIntSlice(t, expected, codes, msg)
37 }
38
39 runTest("alcool", 924, 163, 238, 432, 766, 244)
40 runTest("alcoolique", 901, 163, 238, 432, 766, 244, 105, 113, 117, 101)
41}

Callers

nothing calls this directly

Calls 2

encodeBinaryFunction · 0.85
compareIntSliceFunction · 0.85

Tested by

no test coverage detected