public async void QuestionAccordingToChoices()
        {
            if (GetQuestions.choicesMade == "Yes,")
            {
                GetProductList productList = new GetProductList();
                await productList.GetProductsMatchingTheChoices(GetQuestions.question);

                QuestionBlock display = productList.GetQuestion();
                panelForQuestion.Children.Add(display);
                count += 1;
            }
            else
            {
                GetQuestions getQuestions = new GetQuestions();
                getQuestions.SetPreviousQuestion();
                panelForQuestion.Children.RemoveAt(count);
                count -= 1;
            }
        }
Ejemplo n.º 2
0
        public async void Test3()
        {
            GetProductList  getProductList = new GetProductList();
            RequestResponse choices        = new RequestResponse()
            {
                Layer            = "lastLayer",
                LayerMembers     = new[] { "End" },
                ChoiceDictionary = new Dictionary <string, string[]>()
                {
                    { "startLayer", new[] { "" } },
                    { "Features", new[] { "" } },
                    { "Services", new[] { "" } },
                    { "DisplaySize", new[] { "" } }
                }
            };
            await getProductList.GetProductsMatchingTheChoices(choices);

            var products = GetProductList.productListByChoices;

            Assert.Empty(products);
        }