After installing the ruby and watir environments, you must first find the watir-webdriver code editor, in the previous blog "Ruby + watir automated test environment setup", we mentioned the following: rubymine (Development-specific), SciTE, and NETBeans (ruby-supported) and Eclipse (to install the plug-in Ruby Development Tools ).
Ruby Editor: http://download.csdn.net/detail/wy3552128/4797736
In the future, I plan to use Eclipse as my Ruby editor. At first, I used SciTE to write watir (for learning ). On the Internet, I asked other students who are doing watir and webdriver automation. Most of them use this eclipse editor. Maybe they also use eclipse to develop code.
Download eclipse address: http://big.uzzf.com/eclipse_cn.zip
Download Ruby development plug-in (RDT) Address: http://jaist.dl.sourceforge.net/sourceforge/rubyeclipse/org.rubypeople.rdt-0.7.0.601192300PRD.zip
JDK1.6 official download _ JDK6 official: http://www.java.net/download/jdk6/6u10/promoted/b32/binaries/jdk-6u10-rc2-bin-b32-windows-i586-p-12_sep_2008.exe
Install JDK, eclipse, RDT, and org. rubypeople. the features and plugins folders under rdt are all put in the corresponding folder under the eclipse root directory to complete Ruby plug-in installation:
Org. rubypeople. rdt-0.7.0.601192300PRD \ features ----> eclipse_cn \ features
Org. rubypeople. rdt-0.7.0.601192300PRD \ plugins ------> eclipse_cn \ plugins
After the installation is successful, start eclipse to configure the ruby environment:
Open the eclipse development interface, use the window -- preference -- Ruby -- Installed interpretesto determine the location of ruby.exe (C: \ Ruby \ bin \ ruby.exe), and click OK.
Create a Ruby project and try it out. Create a test. rb file under the ruby project, enter puts "hello, world !!",, Click "run" and select "Ruby application" to run the program. However, you cannot run the program. You need to configure the test. rb script in the "run" configuration. Click "run.