MCPcopy Create free account
hub / github.com/distributedio/titan / MSetEqual

Method MSetEqual

tools/autotest/cmd/string.go:262–276  ·  view source on GitHub ↗

MSetEqual verify that the return value of the mset operation is correct

(t *testing.T, args ...string)

Source from the content-addressed store, hash-verified

260
261//MSetEqual verify that the return value of the mset operation is correct
262func (es *ExampleString) MSetEqual(t *testing.T, args ...string) {
263 as := make([]interface{}, len(args))
264 for i := 0; i < len(args); i = i + 2 {
265 es.values[args[i]] = args[i+1]
266 as[i] = args[i]
267 as[i+1] = args[i+1]
268 }
269 reply, err := redis.String(es.conn.Do("MSET", as...))
270 assert.NoError(t, err)
271 assert.Equal(t, "OK", reply)
272
273 for i := 0; i < len(args); i = i + 2 {
274 es.GetEqual(t, args[i])
275 }
276}
277
278//MSetEqualErr verify that the return value of the mset operation is correct
279func (es *ExampleString) MSetEqualErr(t *testing.T, errValue string, args ...interface{}) {

Callers 1

StringCaseMethod · 0.80

Calls 2

GetEqualMethod · 0.95
StringMethod · 0.45

Tested by

no test coverage detected