Esempio n. 1
0
        public void SelectShopRanking()
        {
            using (var client = new SexAnnualVoteClient())
            {
                var result = client.SelectShopRanking(new Models.Requests.SexAnnualVoteQueryRequest()
                {
                    PageIndex = 1,
                    PageSize  = 10
                });
                result.ThrowIfException(true);
                Assert.AreEqual(result.Result.Source.Any(), true);
                result = client.SelectShopRanking(new Models.Requests.SexAnnualVoteQueryRequest()
                {
                    PageIndex  = 1,
                    PageSize   = 10,
                    ProvinceId = 1
                });
                result.ThrowIfException(true);
                Assert.AreEqual(result.Result.Source.Any(), true);

                result = client.SelectShopRanking(new Models.Requests.SexAnnualVoteQueryRequest()
                {
                    PageIndex  = 1,
                    PageSize   = 10,
                    ProvinceId = 1,
                    Keywords   = "22"
                });
                result.ThrowIfException(true);
                Assert.AreEqual(result.Result.Source.Any(), true);
            }
        }
Esempio n. 2
0
 public void GetShopEmployeeRegionAsync()
 {
     using (var client = new SexAnnualVoteClient())
     {
         var result = client.GetShopEmployeeRegion();
         result.ThrowIfException(true);
         Assert.AreEqual(result.Result.Count > 0, true);
     }
 }
Esempio n. 3
0
 public void AddShareShopVote()
 {
     using (var client = new SexAnnualVoteClient())
     {
         var result = client.AddShareShopVote(Guid.Parse("{607084d4-36fc-4f37-94b7-b68c77921f60}"), 1);
         result.ThrowIfException(true);
         Assert.AreEqual(result.Result, true);
     }
 }
Esempio n. 4
0
 public void FetchShopEmployeeDetail()
 {
     using (var client = new SexAnnualVoteClient())
     {
         var result = client.FetchShopEmployeeDetail(11727, 10319);
         result.ThrowIfException(true);
         Assert.AreEqual(result.Result == null, false);
     }
 }
Esempio n. 5
0
 public void AddShareShopEmployeeVote()
 {
     using (var client = new SexAnnualVoteClient())
     {
         var result =
             client.AddShareShopEmployeeVote(Guid.Parse("{208592FF-19BE-41A4-AF18-4FBFD8D3281A}"), 1, 1);
         result.ThrowIfException(true);
         Assert.AreEqual(result.Result, true);
     }
 }
Esempio n. 6
0
 public void SelectShopEmployeeVoteRecord()
 {
     using (var client = new SexAnnualVoteClient())
     {
         var result = client.SelectShopEmployeeVoteRecord(Guid.Parse("{607084d4-36fc-4f37-94b7-b68c77921f60}"),
                                                          DateTime.Now, DateTime.Now);
         result.ThrowIfException(true);
         Assert.AreEqual(result.Result.Any(), true);
     }
 }
Esempio n. 7
0
 public void CheckEmployeeSignUp()
 {
     using (var client = new SexAnnualVoteClient())
     {
         var result = client.CheckEmployeeSignUp(1, 1);
         result.ThrowIfException(true);
         Assert.AreEqual(result.Result, true);
         result = client.CheckEmployeeSignUp(1, 0);
         result.ThrowIfException(true);
         Assert.AreEqual(result.Result, false);
     }
 }
Esempio n. 8
0
 public void AddShopSignUp()
 {
     using (var client = new SexAnnualVoteClient())
     {
         var result = client.AddShopSignUp(new Models.ShopVoteModel()
         {
             ShopId        = 1,
             Area          = "50平方米",
             CreateDate    = "2016年",
             Description   = "介绍",
             ImageUrls     = Newtonsoft.Json.JsonConvert.SerializeObject(new string[] { "1", "2" }),
             EmployeeCount = 2
         });
         result.ThrowIfException(true);
         Assert.AreEqual(result.Result, true);
     }
 }
Esempio n. 9
0
 public void AddEmployeeSignUp()
 {
     using (var client = new SexAnnualVoteClient())
     {
         var result = client.AddEmployeeSignUp(new Models.ShopEmployeeVoteModel()
         {
             Age               = 1,
             City              = "上海",
             Description       = "介绍",
             EmployeeId        = 1,
             ExpertiseModels   = "路虎",
             ExpertiseProjects = "轮胎",
             Hobby             = "没有",
             ImageUrls         = Newtonsoft.Json.JsonConvert.SerializeObject(new string[] { "1", "2" }),
             Name              = "张三",
             ShopId            = 1,
             VideoUrl          = "",
             YearsEmployed     = 1
         });
         result.ThrowIfException(true);
         Assert.AreEqual(result.Result, true);
     }
 }