You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
49 lines
1.2 KiB
49 lines
1.2 KiB
using TestAutomation.Utils; |
|
|
|
namespace TestAutomation.Pages; |
|
|
|
public class DatabaseSinglePage : BasePage |
|
{ |
|
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 override string Url { get; set; } = "database"; |
|
|
|
|
|
public DatabaseSinglePage GetEntityName(out string result) |
|
{ |
|
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; |
|
} |
|
|
|
public DatabaseSinglePage Goto(string searchText) |
|
{ |
|
Website.Goto($"{Url}/{searchText}"); |
|
return this; |
|
} |
|
} |