(t *testing.T)
| 269 | } |
| 270 | |
| 271 | func TestStringSetEx(t *testing.T) { |
| 272 | args := make([]string, 3) |
| 273 | key := "setex" |
| 274 | args[0] = key |
| 275 | args[1] = "10000" |
| 276 | args[2] = value |
| 277 | |
| 278 | ctx := ContextTest("setex", args...) |
| 279 | Call(ctx) |
| 280 | assert.Contains(t, ctxString(ctx.Out), "OK") |
| 281 | EqualGet(t, key, value, nil) |
| 282 | |
| 283 | args[1] = "x" |
| 284 | ctx = ContextTest("setex", args...) |
| 285 | Call(ctx) |
| 286 | assert.Contains(t, ctxString(ctx.Out), ErrInteger.Error()) |
| 287 | } |
| 288 | |
| 289 | func TestStringSetNx(t *testing.T) { |
| 290 | args := make([]string, 2) |
nothing calls this directly
no test coverage detected