Can Selinium IDE work with CSV on Windows?

1,336 views
Skip to first unread message

Nick M

unread,
Apr 20, 2012, 12:03:19 PM4/20/12
to Selenium Users
Hi Everyone,

Happy Friday. I am embarrassed to write this but after 2 days of
looking I just keep hitting a dead end.

Is there an easy way to get Selenium IDE to parametrize and read the
data from a CSV file or similar on a Windows host running FireFox?

I know I can export scripts, setup the server, learn a new programming
language, and try to wire it all up that way but my needs are basic
and I am just trying to automate some data entry.

I tried iMacros, DejaClick, Sahi, and a few others but only Selenium
seems to work with the JavaScript recursive tree view drop downs we
use without having to record fragile X/Y coordinates and clicks which
can't be parametrized anyway.

Thank you for your help everyone

Best

Nick M.

Matthew Kastor

unread,
Apr 22, 2012, 6:59:17 AM4/22/12
to seleniu...@googlegroups.com
Happy Sunday Nick. :D So, you're wanting to do some data driven tests from Selenium IDE right? Feed Selenium a file containing some data and use that data in tests against a web application? I've got a link for you, http://wiki.openqa.org/display/SEL/datadriven. Let me know if the setup described is working for you.

That is all very complicated stuff that can be solved with programming, voodo, and a cheese burger. :D I don't know if adding the extensions and creating tests so far outside of the default setup will yield you anything useful if you try exporting the tests into one of those fancy programming languages. Like you said though, if you want to use it as the best automation tool for Firefox (because it is), then you probably don't care about setting up a server and running tests on other browsers... unless the web app does something crazy, like not work on Firefox... Anyway, I'll be trying out the datadriven extension eventually. I'm curious about parsing the csv file once it's in Selenium... or should it be an XML file instead... or ... or ... hmm. I've got issues with a "cloud" based "solution" where writing an xml file by hand and feeding it into an automation framework would take a lot less time than waiting for . . . you know what I mean. ;)

Failing that... with a little bit of PHP 5.4 you could take advantage of it's built in web server. With just a line or two of code (taken straight from the examples) you could have the page served right from your laptop (no open ports necessary). From there you could use javascript to "storeEval" whatever you might want. I think I'll be trying this method first since I can just download the php zip file for windows, slap something together in a few seconds, and eventually get around to maybe using the third party php binding for Selenium if things get too complicated. :D I bet python could do the same thing pretty easily, or pretty much any of the supported languages. Well, here's another link for an example of hosting a couple pages from arbitrary folders on my machine http://matthewkastor.blogspot.com/2012/04/phps-built-in-server-super-fun-basic.html... Wait.... can Selenium access files on your desktop by telling it to open file:///c:/somesecretcsvfile.csv ? hmmm... On third thought, I'll try that right now. . . It works. . . seems like there was some security setting in firefox pertaining to the file:/// protocol or something... you'll find it if it effects you. ;) Anyway, now we have 3 options which avoid getting out of the IDE. Lets find an easy method so I can teach 12 year olds how to spam their friends :P

Abhishek Jain

unread,
Oct 20, 2014, 4:11:24 PM10/20/14
to seleniu...@googlegroups.com, nmatt...@vcsonline.com
Hi,

go to this site it contains your answer.

Reply all
Reply to author
Forward
0 new messages