Beispiel #1
0
 public void CheckTableContainRow(ITableWrapper table, string behavior, string value, IElementCollectionWrapper column)
 {
     Assert.ShouldBecome(() => column.Stale, false, $"{column.Caption} is stale");
     Assert.ShouldBecome(() => table.Text.Contains(value), true, $"{table.Caption} text is {table.Text}");
     Assert.ShouldBecome(() => column.Elements.Any(x => x.Stale), false,
                         $"{table.Caption} elements are stale");
     ListServices.GetElementsTextsList(column.Elements).Contains(value).Should().Be(!behavior.Contains("not"));
 }
Beispiel #2
0
        public void CheckRowValuesAreBetween(IElementCollectionWrapper column, string behavior, int value1, int value2)
        {
            Assert.ShouldBecome(() => column.Stale, false, $"{column.Caption} is stale");
            var elementsText = ListServices.GetElementsTextsList(column.Elements);

            Assert.ShouldBecome(() => ListServices.CheckValuesAreBetween(elementsText, value1, value2),
                                !behavior.Contains("not"),
                                $"values are {elementsText.Aggregate((x, y) => $"{x}, {y}")}");
        }
Beispiel #3
0
        public void CompareTableRowGreaterLesser(IElementCollectionWrapper column, string condition,
                                                 int value)
        {
            Assert.ShouldBecome(() => column.Stale, false, $"{column.Caption} is stale");
            var elementsText = ListServices.GetElementsTextsList(column.Elements);

            Assert.ShouldBecome(() => ListServices.CheckListValuesLesserGreater(elementsText, condition, value), true,
                                $"values are {elementsText.Aggregate((x, y) => $"{x}, {y}")}");
        }