Add codec to restlient test.

I've seen the error recently:
```
--- FAIL: TestDoRequest (0.00 seconds)
panic: runtime error: invalid memory address or nil pointer dereference [recovered]
        panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xb code=0x1 addr=0x28 pc=0x44fe39]
```

After some dig in, I find that Codec is nil, but I don't know why travis is passing, am i missing something?

Oh, nice. Done