Fan website of IMMORTAL: Gates of Pyre.
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.
 
 
 
 

29 lines
637 B

using TestAutomation.Shared;
using TestAutomation.Utils;
namespace TestAutomation.Pages;
public abstract class BasePage : BaseElement
{
protected BasePage(Website website) : base(website)
{
}
private IEnumerable<string> Links =>
Website.FindAllWithTag(Website.Find("content"), "a")
.Select(x => x.GetAttribute("href"));
public abstract string Url { get; set; }
public IEnumerable<string> GetLinks()
{
try
{
return Links;
}
catch (Exception e)
{
throw new Exception($"Couldn't get links on page {Url}");
}
}
}