public void TestChoiceWithSetArrays() { var request = new GroupCallCenterAddAgentListRequest() { ServiceUserId = "*****@*****.**", AgentUserId = new List <string>() { "*****@*****.**" }, AgentSkillList = new List <CallCenterSkillAgentList>() { new CallCenterSkillAgentList() { Agent = new List <string>() { "test" }, SkillLevel = 1 } } }; var results = Validator.Validate(request); Assert.False(results.Success); Assert.IsType <InvalidChoiceError>(results.Errors.Single()); }
public void TestChoiceWithUnsetArrays() { var request = new GroupCallCenterAddAgentListRequest() { ServiceUserId = "*****@*****.**" }; var results = Validator.Validate(request); Assert.False(results.Success); Assert.IsType <ChoiceNotSetError>(results.Errors.Single()); }
public void TestChoiceWithEmptyArrays() { var request = new GroupCallCenterAddAgentListRequest() { ServiceUserId = "*****@*****.**", AgentUserId = new List <string>() { "*****@*****.**" } }; var results = Validator.Validate(request); Assert.True(results.Success); }