Posted by testcrunch on 9th December 2009
Someone has asked me to see if I can get Selenium working in anger over the next week, a good challenge.
I think they use it on Windows but I’ve read that it is a plug-in for Firefox and therefore I assumed only works on Firefox. No doubt that will become clear soon. I downloaded Selenium RC and installed it. Got its java server working, well it fired up a couple of things and is sitting there waiting for something to happen. I’m supposed to be using Perl but as I’ve found some idiot notes on checking whether the Selenium stands up using Python, then that’s what I tried. Downloaded Python and installed it. Copied some python code into a file, changed the path to include the Selenium python client, started the python gui, opened my test .py file and ran the critter. Of course I get an error message that it’s expecting an indented block. Does it really mean that it wants indented code. I can indent some code but that probably isn’t the problem and I’ll probably end up messing with this for too long and I’m supposed to be using Perl so I’ll stop playing with python.
Tried to download Active Perl to my XP PC but that failed to download by timing out so tried it on Vista and that failed as well. Eventually got it via a torrent.
I got a horrible virus on XP and even Microsoft’s Onecare didn’t trap it. The virus was delivered via an unequested pdf file. It displayed a message that I had some security problems and wanted me to use their virus checker, which popped up from nowhere. I tried using Task Manager to stop it running, but I got a message about a corrupted file. Tried running a few other things and they all reported corrupt files. Also lost my internet connection. Nothing worked. Don’t panic (Why not? Sounds like a good strategy to me. Ed). Rebooted into safe mode and restored back a day and everything was OK.
Some people that don’t know how to deal with these issues probably do panic and probably mindlessly thrash about for several days trying to sort it out and talk to all sorts of experts who give them all kinds of conflicting advice and eventually they give up, bin the PC and buy a new one. There must be money to be made fixing these problems.
Got my result for my ISEB Intermediate exam and I passed it with only two incorrect answers (Who’d you pay to get that result? Ed).
Posted in ISEB or is that ISTQB?, Selenium - not toxic, Virus - don't feel too good | No Comments »
Posted by testcrunch on 4th November 2009
Someone wanted to know what open source, or just plain free, software existed for the testing of web pages, and it had to be simple to use. No coding.
I had another look at Selenium IDE and that works OK, if you can justify the time to generate working scripts, except it’s got the reputation from hell when using Internet Explorer. I got the plug-in working in Firefox but the client only uses IE so that’s the end of that.
I then had a look at Watir and that took a while to get going. Downloaded the latest Watir file and couldn’t get it to do anything, so started reading. Ah..it needs Ruby, as Watir is a Ruby Gem, whatever that is (A packaged Ruby application or library like Rails. Ed), so downloaded and installed Ruby, which sticks it’s folders at the end of your path so that commands can be run from a command window. It was supposed to come with an IDE called FreeRIDE but it wasn’t there so I downloaded that seperately and that installed OK. I then tried to install Watir with the command ‘gem install watir’ and that failed. More reading and I needed to generate some (all?) of the Ruby Gems. Did that with ‘gem update –system’ (Updates the Gem system. Ed). Checked that they had been generated OK and reran ‘gem install watir’ and again it failed with a message that ‘Commonwatir’ was missing. Installed Commonwatir, and Firewatir, and again tried to install the Watir Ruby Gem, and this time it worked, well it thrashed about a bit and displayed messages saying ‘Successfull’.
OK, so what do I do now? I found some Ruby code for checking a Google search and whether the resultant page contained specific text, in this case ‘Programming Ruby’. Copied the text into Notepad, amended it slightly, saved it with an extension .rb and loaded it into FreeRIDE, hit F5 to run the darn thing and it responded with a message that the text was found correctly. Amended the text to be searched for to some gibberish, saved the file and reloaded it into FreeRIDE and ran it again and as Google had searched for the nonsense I’d asked for, and which most definitely didn’t contain any text called ‘Programming Ruby’, Watir correctly displayed a message that the text was not found. Yikes the critter works.
Normall clunky installation that would have been sped up if I’d coughed up $50 for a Ruby/Watir bible but it does work. Trouble is the client wants software with no coding and Watir seems to be just coding.
Posted in Selenium - not toxic, Watir - record & playback? Nope | 1 Comment »
Posted by testcrunch on 25th July 2008
I started playing with Selenium Core the other day just to see what it does and if nothing else it does do record and playback OK.
Beyond that it’s either finding some documentation on the web or doing some exploratory testing on it to figure out what’s under the hood. I always prefer reading a book on a subject when I trying to learn new stuff and I’ve just had a look on Amazon and there doesn’t seem to be any books on it at all.
I also downloaded Selenium Remote Control which acts as some kind of server and comes with client drivers for Perl, Python, Ruby and Java. I unzipped the download file, installed the server software and started up the (Java) server which actually started two servers. I then created a Python script to get Selenium to open Firefox and login, with Notepad and then came to a shuddering halt. OK I’ve got a Python script how the heck do I run it as Windows doesn’t interpret .py files. I had a quick look at Wikipedia and, of course, I had to download a Python shell. Installed that OK and tried running my noddy script but got a load of syntax errors. Well what do you expect, there is only so much you can do without reading a manual. So get a Python manual.
The iPhone store icon displayed a number on it this morning. They were for updates to a couple of the free apps I had downloaded. I clicked to update both apps and in an area where I had only 1 bar and 3G starting and stopping like billy-o the darn think still downloaded and installed both of the updated apps. Neat.
Quote of the day
“Men are generally idle, and ready to satisfy themselves, and intimidate the industry of others, by calling that impossible which is only difficult” Samuel Johnson (1709-1784)
Posted in Python - how do I run it, Selenium - not toxic | No Comments »