Selenium With .Net

Recently I had a chance to work with Selenium framwork. It is pretty easy to intrgrate automated testing into .net with Selenium. Also for project like web site scrapping and automated posting, can be easily developped with few lines of code. Following code lines will automate a web site login with use of selenium framework.

ISelenium selenium = new DefaultSelenium(seleniumServer, port, browser, website);
selenium.WaitForPageToLoad((ConfigLoader.Configurations.WaitingTime * 1000).ToString());
selenium.Type("ctl00_PageContent_UserName", ConfigLoader.Configurations.UserName);
selenium.Type("ctl00_PageContent_Password", ConfigLoader.Configurations.Password);
selenium.WaitForPageToLoad((ConfigLoader.Configurations.WaitingTime * 1000).ToString());


Post a Comment

Popular posts from this blog

CSS text-overflow ellipsis in the beginning of the the text - Left Ellipsis using CSS in a Flex box

Handling Exit Event of Console Application in C#