Search
 
 

Display results as :
 


Rechercher Advanced Search

Navigation
 Portal
 Index
 Memberlist
 Profile
 FAQ
 Search

Locators in WebDriverBackedSelenium

View previous topic View next topic Go down

Locators in WebDriverBackedSelenium

Post by theYoRecords on Sat Dec 01, 2012 10:07 pm

Hey there,

I've got a problem by locating elements with WebDriverBackedSelenium in an open WebDriver-Session.
According to all information i found these locators are for example Css-Locators, IDs, XPath and so on. But I can't get this to work. By the way I'm using C#.

Here's an example:

This works:
driver.FindElement(By.Id("test")).Click();
But this doesn't:
wdb.Click("id='test'");

Can you tell me what's wrong?
And is it correct to initialize the WDBSelenium like that:
var wdb = new WebDriverBackedSelenium(driver, driver.URL);
wdb.Start();

Thanks!

theYoRecords

Posts : 2
Join date : 2012-10-26

Back to top Go down

Re: Locators in WebDriverBackedSelenium

Post by tarun3kumar on Tue Dec 04, 2012 2:15 pm

Are you migrating from Sel1 to Sel2 ?
Also can you try - wdb.Click("'test'");

_________________
Thanks
Tarun K
Free Selenium Training

tarun3kumar
Master
Master

Posts : 186
Join date : 2012-02-14

http://seleniumtests.com

Back to top Go down

Re: Locators in WebDriverBackedSelenium

Post by theYoRecords on Sat Dec 08, 2012 9:35 pm

tarun3kumar wrote:Are you migrating from Sel1 to Sel2 ?
Also can you try - wdb.Click("'test'");



Thanks for your reply!

I´m migrating from WatiN to Sel2.

The problem has been solved. In the example above I should have used

wdb.Click("id=test");

and anyway I didn´t recognize that I normally have to start with the locator-specification (css=, xpath=).

theYoRecords

Posts : 2
Join date : 2012-10-26

Back to top Go down

Re: Locators in WebDriverBackedSelenium

Post by Sponsored content Today at 7:23 am


Sponsored content


Back to top Go down

View previous topic View next topic Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum