Skip to content
This repository has been archived by the owner on Sep 1, 2022. It is now read-only.

Navigation

Cezary Piątek edited this page Mar 30, 2017 · 4 revisions

Navigation

First of all you have to define application root url in BrowserAdapterConfig

var browserAdapterConfig = new BrowserAdapterConfig()
{
    PageUrl = "http://my.website.lan:5000"
};

or using configuration file:

<telluriumConfiguration pageUrl="http://my.website.lan:5000" />

In order to open given page in browser use NavigateTo function

private static void OpenDocumentsList(IBrowserAdapter browser)
{
	browser.NavigateTo("/Documents/Index");
}

For ASP.NET MVC project you can use strongly typed overload which accepts Expression representing given controller's action

private static void OpenDocumentsList(IBrowserAdapter browser)
{
	browser.NavigateTo<DocumentsController>(c => c.Index());
}

You can also reload current page

browser.RefreshPage();