public static void ImplementTestAction(this TestElementAction action)
        {
            switch (action.ElementType)
            {
            case "Button":
                Selenium.ClickField(Identifiers.Buttons[action.ElementId]);
                break;

            case "TextBox":
                Selenium.EditTextField(Identifiers.TextFields[action.ElementId], action.ElementContent);
                break;

            case "Combo":
                Selenium.SetComboByText(Identifiers.TextFields[action.ElementId], action.ElementContent);
                break;

            default:
                break;
            }
        }
Example #2
0
        public List <SingleExecutionFull> GetExecSteps()
        {
            var res = new List <SingleExecutionFull>();
            TestElementAction action = null;

            try
            {
                for (int i = 0; i < TestActions.Count; i++)
                {
                    action = TestActions[i];
                    SingleExecutionFull currentExec = GetInitialExecStep();
                    currentExec.AssociatedAction = action;
                    res.Add(currentExec);
                }

                return(res);
            }
            catch (Exception x)
            {
                x.Data.Add("action", action);
                throw;
            }
        }