Selenium Forum: Functional And Regression Testing Tool.
Would you like to react to this message? Create an account in a few clicks or log in to continue.
Search
Display results as :
Advanced Search
Latest topics
AEM Training | Free Online DemoWed Apr 21, 2021 5:45 pmazharuddin
c# PageFactory - issue initializing elementsFri Nov 01, 2019 8:40 pmthegoatboy
Selenium making automatic connection to random urlsMon Jul 08, 2019 12:58 pmrepairtechsolutions1
How can we design the custom framework in Selenium RCMon Jun 24, 2019 2:26 pmrandybonnettes
What are the new features in Selenium 3.0Tue Jun 18, 2019 5:37 pmpappyvicky
What are you using Selenium for? Fri Apr 12, 2019 3:52 amzhl
LIMITATIONS OF SELENIUMWed Apr 10, 2019 11:23 amswara
Navigation
 Portal
 Index
 Memberlist
 Profile
 FAQ
 Search

Go down
avatar
Yariv-H
Posts : 2
Join date : 2015-06-29

Which command in the IDE reflected info driver.findElements while exporting to JUNIT code? Empty Which command in the IDE reflected info driver.findElements while exporting to JUNIT code?

Mon Jun 29, 2015 7:09 pm
I'm trying to understand if there is a way to see the mapping between the commands from selenium IDE into the JUNIT code while exporting these test cases?

From the java code i was able to use driver.findElements and getting List, is there a way to do so form the IDE?

I'm just looking for a quick way to use the IDE in order to located all the info i need from the web page, than export it into java code and modify the last tuning from the code.

Thanks for the help,
Yariv.
avatar
ccox
Master
Master
Posts : 205
Join date : 2012-01-06
Age : 39
Location : Denver, CO

Which command in the IDE reflected info driver.findElements while exporting to JUNIT code? Empty Re: Which command in the IDE reflected info driver.findElements while exporting to JUNIT code?

Mon Jun 29, 2015 11:35 pm
No there isn't. As far as I know, javascript/selenium doesn't use lists and the tool is not built to iterate through any lists. You would have to build your own function to do this which won't save time. You could try using getEval and getElementsByTagName(), but again, it won't help your end goal. 

Just curious as to why you are exporting these? From my experience, exporting tests leads to poor practices and ends up adding more time to maintain. Copy and pasting lines is one thing, but exporting turns into a nightmare.
avatar
Yariv-H
Posts : 2
Join date : 2015-06-29

Which command in the IDE reflected info driver.findElements while exporting to JUNIT code? Empty Re: Which command in the IDE reflected info driver.findElements while exporting to JUNIT code?

Tue Jun 30, 2015 2:05 pm
ccox wrote:No there isn't. As far as I know, javascript/selenium doesn't use lists and the tool is not built to iterate through any lists. You would have to build your own function to do this which won't save time. You could try using getEval and getElementsByTagName(), but again, it won't help your end goal. 

Just curious as to why you are exporting these? From my experience, exporting tests leads to poor practices and ends up adding more time to maintain. Copy and pasting lines is one thing, but exporting turns into a nightmare.


Gotya, My main goal was to use selenium framework in order to perform an advance web crawling for 3-th party web sites, there for i need to use some pulled info and compere it with the current one on the website it self.

If your question why to use selenium, this is the only framework i found that overcome the bot detection in a lot of website and it is the closest to human activity Smile


If you have any other recommendation i would like to hear them. As well if you have a good cook book for "writing your own commands" or something like that.

Thansk,
Yariv.
avatar
ccox
Master
Master
Posts : 205
Join date : 2012-01-06
Age : 39
Location : Denver, CO

Which command in the IDE reflected info driver.findElements while exporting to JUNIT code? Empty Re: Which command in the IDE reflected info driver.findElements while exporting to JUNIT code?

Tue Jun 30, 2015 9:11 pm
Are you just using IDE to create the tests and then exporting them as JUnit? Or are you actually using IDE to run these tests?

It wouldn't make sense to maintain the same scripts in two formats, let alone build custom functions in IDE when you have them in webdriver. But like I said, you can always use the getEval command in IDE which will execute javascript commands.

My question isn't why are you using selenium, but why are you exporting tests? If you are recording in Selenium IDE, you can copy and paste in a clipboard format of your choice, eliminating the export. Exporting the tests gives you basically a single class for all of your tests and functions. This is a poor practice since with Selenium you should be using a page object pattern. Hopefully this makes sense.
avatar
seluserqwb1
Active particpant
Active particpant
Posts : 20
Join date : 2015-06-29

Which command in the IDE reflected info driver.findElements while exporting to JUNIT code? Empty Re: Which command in the IDE reflected info driver.findElements while exporting to JUNIT code?

Mon Jul 06, 2015 8:09 pm
Message reputation : 0% (1 vote)
Please post your question in official webdriver forum  - 
www.seleniumtests.com/p/selenium-2-forum.html
Sponsored content

Which command in the IDE reflected info driver.findElements while exporting to JUNIT code? Empty Re: Which command in the IDE reflected info driver.findElements while exporting to JUNIT code?

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