Auto formatting
This commit is contained in:
@@ -6,39 +6,41 @@ namespace TestAutomation.Pages;
|
||||
|
||||
public class DatabasePage : BaseElement
|
||||
{
|
||||
|
||||
public DatabasePage(Website website) : base(website)
|
||||
{
|
||||
}
|
||||
|
||||
private IWebElement FilterNameInput => Website.Find("filterName");
|
||||
|
||||
|
||||
private ReadOnlyCollection<IWebElement> EntityNames() =>
|
||||
Website.FindAll("entityName");
|
||||
|
||||
|
||||
private IWebElement EntityName(string entityType, string entityName) =>
|
||||
Website.Find("entityName",
|
||||
private ReadOnlyCollection<IWebElement> EntityNames()
|
||||
{
|
||||
return Website.FindAll("entityName");
|
||||
}
|
||||
|
||||
|
||||
private IWebElement EntityName(string entityType, string entityName)
|
||||
{
|
||||
return Website.Find("entityName",
|
||||
$"{entityType.ToLower()}-{entityName.ToLower()}");
|
||||
|
||||
|
||||
public DatabasePage(Website website) : base(website) { }
|
||||
}
|
||||
|
||||
public DatabasePage FilterName(string name)
|
||||
{
|
||||
Website.EnterInput(FilterNameInput, name);
|
||||
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
public DatabasePage GetEntityName(string entityType, string entityName, out string result)
|
||||
{
|
||||
result = EntityName(entityType, entityName).Text;
|
||||
return this;
|
||||
}
|
||||
|
||||
public DatabasePage GetEntityName(int index,out string result)
|
||||
|
||||
public DatabasePage GetEntityName(int index, out string result)
|
||||
{
|
||||
result = EntityNames()[index].Text;
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -5,13 +5,15 @@ namespace TestAutomation.Pages;
|
||||
|
||||
public class DatabaseSinglePage : BaseElement
|
||||
{
|
||||
public DatabaseSinglePage(Website website) : base(website)
|
||||
{
|
||||
}
|
||||
|
||||
private IWebElement EntityName => Website.Find("entityName");
|
||||
private IWebElement EntityHealth => Website.Find("entityHealth");
|
||||
|
||||
|
||||
private IWebElement InvalidSearch => Website.Find("invalidSearch");
|
||||
private IWebElement ValidSearch => Website.Find("validSearch");
|
||||
|
||||
public DatabaseSinglePage(Website website) : base(website) { }
|
||||
|
||||
|
||||
public DatabaseSinglePage GetEntityName(out string result)
|
||||
@@ -19,23 +21,22 @@ public class DatabaseSinglePage : BaseElement
|
||||
result = EntityName.Text;
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
public DatabaseSinglePage GetEntityHealth(out string result)
|
||||
{
|
||||
result = EntityHealth.Text;
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
public DatabaseSinglePage GetInvalidSearch(out string result)
|
||||
{
|
||||
result = InvalidSearch.Text;
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
public DatabaseSinglePage GetValidSearch(out string result)
|
||||
{
|
||||
result = ValidSearch.Text;
|
||||
return this;
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user