1234567891011121314151617181920212223242526272829303132333435363738394041 |
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- using JCSoft.WX.Framework.Models.ApiRequests;
- using JCSoft.WX.Framework.Models.ApiResponses;
- using Xunit;
- namespace FrameworkCoreTest.Api
- {
- public class CustomserviceKfsessionCreateTest : MockPostApiBaseTest<CustomserviceKfsessionCreateRequest, CustomserviceKfsessionCreateResponse>
- {
- protected override CustomserviceKfsessionCreateRequest InitRequestObject()
- {
- return new CustomserviceKfsessionCreateRequest
- {
- AccessToken = "123",
- KfAccount = "kf@kf.com",
- OpenId = "123lkjzcv",
- Text = "this is test text"
- };
- }
- protected override string GetReturnResult(bool errResult)
- {
- if (errResult) return s_errmsg;
- return @"{
- ""kf_account"" : ""test1@test"",
- ""openid"" : ""OPENID"",
- ""text"" : ""这是一段附加信息""
- }";
- }
- public override CustomserviceKfsessionCreateResponse GetResponse()
- {
- return mock_client.Object.Execute(Request);
- }
- }
- }
|