Пример #1
0
        private void ExecuteCondition(Func <RWebElement, bool> condition, string conditionName)
        {
            var wait = _automationManager.DefaultWait(_rWebElement);

            wait.Message = $"Failed to get condition: {_expression.Condition.Description} {conditionName}";
            wait.Until(condition);
        }
Пример #2
0
        private void ExecuteCondition(Func <string, string, bool> condition, string expected, string propertyName)
        {
            var wait = _automationManager.DefaultWait(_condition);

            wait.Until(x =>
            {
                var actual   = x.Expression();
                wait.Message =
                    $"Failed to get condition: {_condition.Condition.Description} {propertyName}: {expected}. Actual: {actual} ";
                return(condition(actual.ToString(), expected));
            });
        }
Пример #3
0
 public RWebElementCollection WaitNotZero(bool throwEx = false)
 {
     try
     {
         _automationManager.DefaultWait(this).Until(x => x.Count > 0);
     }
     catch (Exception e)
     {
         if (throwEx)
         {
             throw;
         }
     }
     return(this);
 }