public byte[] GetVerifyCodeImage(VerifyCodeReq req) { _VerifyCodeReq = req; _HttpClient.Reset(); _HttpClient.Url = GetTypeUrl.CombineParam(GetTypeParam()); _ImageReq = _HttpClient.GET().GetImageReq(); _ImageReq.Cap_cd = req.Cap_cd; _ImageReq.UID = req.UID; _HttpClient.Url = GetSig.CombineParam(GetSigParam()); _ImageReq.Vsig = _HttpClient.GET().GetVsig(); _ImageReq.Rand = (new Random().NextDouble()).ToString(); _HttpClient.Url = GetImage.CombineParam(GetImageParam()); return(_HttpClient.GET().GetBytes()); }
public void Shouldbe_GET_Request() { IHttpClient client = new DefaultHttpClient(); client.GET(); Assert.AreEqual(HttpVerb.GET, client.Verb); }
public RegmasterRes Send(RegmasterReq req) { _RegmasterReq = req; _HttpClient.Reset(); _HttpClient.Url = CheckRegmasterUrl.CombineParam(GetCheckRegmasterRequestParam()); return(_HttpClient.GET().GetRemasterRes()); }
public void Shouldbe_URL_GET_Request() { var url = "http://test.com"; IHttpClient client = new DefaultHttpClient(); client.GET(url); Assert.AreEqual(HttpVerb.GET, client.Verb); Assert.AreEqual(url, client.Url); }