public void TestSingleSelectForm()
 {
     string jsonRpcCallId = "jsonrpc id 19347819";
     Messaging.SendFormRequest request = new Messaging.SendFormRequest();
     request.Member = "*****@*****.**";
     request.ParentKey = null;
     request.Flags = 0;
     request.AlertFlags = 0;
     request.Branding = "A68EBEAB5C962B271BD236AAE6595E5C353B56A650F98B760026CAFA094DB8D1";
     request.Text = "What is your favourite literary genre?";
     request.Tag = "my message tag19347819";
     request.Context = null;
     SingleSelectWidget widget = new SingleSelectWidget();
     widget.Value = "1";
     List<Choice> Choices = new List<Choice>();
     Choice choice = new Choice();
     choice.Label = "Fiction";
     choice.Value = "1";
     Choices.Add(choice);
     Choice choice2 = new Choice();
     choice2.Label = "Non-fiction";
     choice2.Value = "2";
     Choices.Add(choice2);
     widget.Choices = Choices;
     request.Form.Widget = widget;
     request.Form.PositiveButtonCaption = "Next question";
     request.Form.NegativeButtonCaption = "Stop poll";
     request.Form.NegativeButtonConfirmation = "Do you really want to stop the poll?";
     Messaging.SendFormResponse response = this.Api.Send(request, jsonRpcCallId);
     Assert.IsNotNull(response.Result);
 }
 public void TestSendSingleSelectForm()
 {
     SingleSelectWidget widget = new SingleSelectWidget();
     Choice choice1 = new Choice();
     choice1.Value = "1";
     choice1.Label = "Fiction";
     widget.Choices.Add(choice1);
     Choice choice2 = new Choice();
     choice2.Value = "2";
     choice2.Label = "Non-fiction";
     widget.Choices.Add(choice2);
     widget.Value = "1";
     ValidateSendForm("What is your favourite literary genre?", widget);
 }