Add the request test case and fix some bugs on request class