MCPcopy
hub / github.com/IBM/sarama / TestSyncGroupRequestV3AndPlus

Function TestSyncGroupRequestV3AndPlus

sync_group_request_test.go:82–157  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

80)
81
82func TestSyncGroupRequestV3AndPlus(t *testing.T) {
83 groupInstanceId := "gid"
84 protocolType := "consumer"
85 protocolName := "range"
86 tests := []struct {
87 CaseName string
88 Version int16
89 MessageBytes []byte
90 Message *SyncGroupRequest
91 }{
92 {
93 "v3",
94 3,
95 populatedSyncGroupRequestV3,
96 &SyncGroupRequest{
97 Version: 3,
98 GroupId: "foo",
99 GenerationId: 0x00010203,
100 MemberId: "baz",
101 GroupInstanceId: &groupInstanceId,
102 GroupAssignments: []SyncGroupRequestAssignment{
103 {
104 MemberId: "baz",
105 Assignment: []byte("foo"),
106 },
107 },
108 },
109 },
110 {
111 "v4",
112 4,
113 populatedSyncGroupRequestV4,
114 &SyncGroupRequest{
115 Version: 4,
116 GroupId: "foo",
117 GenerationId: 0x00010203,
118 MemberId: "baz",
119 GroupInstanceId: &groupInstanceId,
120 GroupAssignments: []SyncGroupRequestAssignment{
121 {
122 MemberId: "baz",
123 Assignment: []byte("foo"),
124 },
125 },
126 },
127 },
128 {
129 "v5",
130 5,
131 populatedSyncGroupRequestV5,
132 &SyncGroupRequest{
133 Version: 5,
134 GroupId: "foo",
135 GenerationId: 0x00010203,
136 MemberId: "baz",
137 GroupInstanceId: &groupInstanceId,
138 ProtocolType: &protocolType,
139 ProtocolName: &protocolName,

Callers

nothing calls this directly

Calls 3

testVersionDecodableFunction · 0.85
testEncodableFunction · 0.85
ErrorfMethod · 0.65

Tested by

no test coverage detected