Has anyone successfully set up a standalone environment for using ruby 1.9.2, selenium-client, and rspec to test a NON-RAILS website.
I have scoured the web but I cannot seem to get the magic formula. There are gem version conflicts, missing libraries, etc. At this point I am totally confused.
BASIC PROBLEM: I have many test suites and tests ceated using SeleniumIDE 1.0.10 for a NON-RAILS application (IIS/ASP). I SIMPLY want to use the converted tests that the SeleniumIDE can provide and run them using ruby or better yet rake. (Note that the SeleniumIDE can create RSpec or Test/Unit tests and I would be love to get either working).
As I understand it the selenium-client has rake tasks to start/stop the SeleniumRC server and to run tests. But for the life of me I cannot get any of this this going.
I can provide more information if need be. But, at this point I would be happy to know of anyone that is also going down this road.
-Thanks!
P.S. I am doing this as a prelude to hybridizing the IIS/ASP application with rails and iteratively going to a full conversion. If I cannot get this first step going my bosses are going to nix the whole idea of going to rails, so please help 😉
You will need to gem install ‘rspec’ and ‘selenium-client’. I have ruby 1.9.2 installed and yes, I use rvm. I apologize for the firefox_version nonsense. I have multiple firefox versions installed on my Macbook. If you have a single firefox installed then simply specify :browser => “*firefox”
You will need to open two Terminal windows. In the first, start the selenium-server.jar.
In the second window, cd to the directory containing rspec_hello.rb and enter
ruby ./rspec_hello.rb
Here is rspec_hello.rb