Browser Commands


The Browser commands are generally the ones which we intuitively feel that a browser should control. Examples include “type URL and hit enter”, “get title”, ”back”, ”forward” and so on.


It is assumed that you have downloaded the Class1 code base –


  1. Simple SpecFlow scenario registering a new user
  2. Selenium scenario
  3. Browser title, current URL, and page sources
  4. Browser forward, backward and refresh

1. Navigate to url (Go to a URL)

2. Browser title

 3. Browser back

 4. Browser forward

 5. Browser refresh

 6. Browser current URL


  1. Once you have downloaded the code-base, open it in Visual Studio by double clicking the solution file (RegistrationDemo.sln) that is found in the root of the source path.
  2. There are two SpecFlow scenarios: UserRegistration.feature and BrowserCommands.feature
  3. Right click anywhere within the feature file and select Run Tests.  Details of putting together the test project have been explained within the Add Test Project tutorial.

After importing the project into Visual Studio, it should look like the following:




Command line output