selenium-rspec-dsl 1.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (236) hide show
  1. data/common/shared/common.rb +167 -0
  2. data/config/aggregate_reports.rb +124 -0
  3. data/config/array_extension.rb +13 -0
  4. data/config/multi_process_behaviour_runner.rb +50 -0
  5. data/config/selenium-setup.rb +32 -0
  6. data/config/site_config.rb +8 -0
  7. data/sites/button.rb +31 -0
  8. data/sites/buttonAjax.rb +14 -0
  9. data/sites/buttonJQuery.rb +26 -0
  10. data/sites/buttonMultiWindow.rb +99 -0
  11. data/sites/buttonNonLoad.rb +11 -0
  12. data/sites/checkbox.rb +22 -0
  13. data/sites/checkboxExtjs.rb +10 -0
  14. data/sites/checkboxGwt.rb +24 -0
  15. data/sites/dropdown.rb +28 -0
  16. data/sites/dropdownAjax.rb +40 -0
  17. data/sites/dropdownExtjs.rb +32 -0
  18. data/sites/dropdownJQuery.rb +40 -0
  19. data/sites/dropdownLoad.rb +25 -0
  20. data/sites/element.rb +172 -0
  21. data/sites/form.rb +7 -0
  22. data/sites/image.rb +7 -0
  23. data/sites/label.rb +32 -0
  24. data/sites/link.rb +32 -0
  25. data/sites/linkMultiWindow.rb +160 -0
  26. data/sites/linkNonLoad.rb +11 -0
  27. data/sites/listbox.rb +16 -0
  28. data/sites/page.rb +16 -0
  29. data/sites/panel.rb +7 -0
  30. data/sites/radiobutton.rb +10 -0
  31. data/sites/tabPanel.rb +7 -0
  32. data/sites/table.rb +48 -0
  33. data/sites/tableExtjs.rb +42 -0
  34. data/sites/test/googleResults_screen.rb +15 -0
  35. data/sites/test/googleSearch_screen.rb +27 -0
  36. data/sites/textbox.rb +16 -0
  37. data/sites/tree.rb +7 -0
  38. data/sites/treeGwt.rb +32 -0
  39. data/spec/spec.opts +6 -0
  40. data/spec/spec_helper.rb +40 -0
  41. data/spec/test/testPass_spec.rb +36 -0
  42. data/spec/test/testPending_spec.rb +13 -0
  43. data/vendor/selenium-client-1.2.17/README.markdown +328 -0
  44. data/vendor/selenium-client-1.2.17/examples/rspec/google_spec.rb +41 -0
  45. data/vendor/selenium-client-1.2.17/examples/script/google.rb +25 -0
  46. data/vendor/selenium-client-1.2.17/examples/testunit/google_test.rb +39 -0
  47. data/vendor/selenium-client-1.2.17/lib/nautilus/shell.rb +32 -0
  48. data/vendor/selenium-client-1.2.17/lib/selenium.rb +14 -0
  49. data/vendor/selenium-client-1.2.17/lib/selenium/client.rb +27 -0
  50. data/vendor/selenium-client-1.2.17/lib/selenium/client/base.rb +118 -0
  51. data/vendor/selenium-client-1.2.17/lib/selenium/client/driver.rb +11 -0
  52. data/vendor/selenium-client-1.2.17/lib/selenium/client/extensions.rb +118 -0
  53. data/vendor/selenium-client-1.2.17/lib/selenium/client/generated_driver.rb +1711 -0
  54. data/vendor/selenium-client-1.2.17/lib/selenium/client/idiomatic.rb +488 -0
  55. data/vendor/selenium-client-1.2.17/lib/selenium/client/javascript_expression_builder.rb +116 -0
  56. data/vendor/selenium-client-1.2.17/lib/selenium/client/javascript_frameworks/jquery.rb +13 -0
  57. data/vendor/selenium-client-1.2.17/lib/selenium/client/javascript_frameworks/prototype.rb +13 -0
  58. data/vendor/selenium-client-1.2.17/lib/selenium/client/protocol.rb +96 -0
  59. data/vendor/selenium-client-1.2.17/lib/selenium/client/selenium_helper.rb +34 -0
  60. data/vendor/selenium-client-1.2.17/lib/selenium/command_error.rb +4 -0
  61. data/vendor/selenium-client-1.2.17/lib/selenium/protocol_error.rb +4 -0
  62. data/vendor/selenium-client-1.2.17/lib/selenium/rake/default_tasks.rb +16 -0
  63. data/vendor/selenium-client-1.2.17/lib/selenium/rake/remote_control_start_task.rb +70 -0
  64. data/vendor/selenium-client-1.2.17/lib/selenium/rake/remote_control_stop_task.rb +44 -0
  65. data/vendor/selenium-client-1.2.17/lib/selenium/rake/tasks.rb +6 -0
  66. data/vendor/selenium-client-1.2.17/lib/selenium/remote_control/remote_control.rb +33 -0
  67. data/vendor/selenium-client-1.2.17/lib/selenium/rspec/reporting/file_path_strategy.rb +78 -0
  68. data/vendor/selenium-client-1.2.17/lib/selenium/rspec/reporting/html_report.rb +123 -0
  69. data/vendor/selenium-client-1.2.17/lib/selenium/rspec/reporting/selenium_test_report_formatter.rb +87 -0
  70. data/vendor/selenium-client-1.2.17/lib/selenium/rspec/reporting/system_capture.rb +72 -0
  71. data/vendor/selenium-client-1.2.17/lib/selenium/rspec/rspec_extensions.rb +96 -0
  72. data/vendor/selenium-client-1.2.17/lib/selenium/rspec/spec_helper.rb +35 -0
  73. data/vendor/selenium-client-1.2.17/lib/tcp_socket_extension.rb +32 -0
  74. data/vendor/selenium-client-1.2.17/test/all_unit_tests.rb +3 -0
  75. data/vendor/selenium-grid-1.0.4/Capfile +107 -0
  76. data/vendor/selenium-grid-1.0.4/README +10 -0
  77. data/vendor/selenium-grid-1.0.4/Rakefile +190 -0
  78. data/vendor/selenium-grid-1.0.4/build.xml +182 -0
  79. data/vendor/selenium-grid-1.0.4/doc/resources/Multiple Environments Demo Setup.svg +518 -0
  80. data/vendor/selenium-grid-1.0.4/doc/resources/Multiple Machine Demo Setup.svg +371 -0
  81. data/vendor/selenium-grid-1.0.4/doc/resources/Rakefile +18 -0
  82. data/vendor/selenium-grid-1.0.4/doc/resources/Requesting a Specific Environment.svg +576 -0
  83. data/vendor/selenium-grid-1.0.4/doc/resources/Selenium Grid Setup.svg +539 -0
  84. data/vendor/selenium-grid-1.0.4/doc/resources/Selenium Grid.css +68 -0
  85. data/vendor/selenium-grid-1.0.4/doc/resources/Traditional Selenium Setup.svg +295 -0
  86. data/vendor/selenium-grid-1.0.4/doc/website/Rakefile +37 -0
  87. data/vendor/selenium-grid-1.0.4/doc/website/diagrams/Multiple Environment Demo Setup - Small.png +0 -0
  88. data/vendor/selenium-grid-1.0.4/doc/website/diagrams/Multiple Environment Demo Setup.png +0 -0
  89. data/vendor/selenium-grid-1.0.4/doc/website/diagrams/Multiple Machine Demo Setup - Small.png +0 -0
  90. data/vendor/selenium-grid-1.0.4/doc/website/diagrams/Multiple Machine Demo Setup.png +0 -0
  91. data/vendor/selenium-grid-1.0.4/doc/website/diagrams/Requesting a Specific Environment - Small.png +0 -0
  92. data/vendor/selenium-grid-1.0.4/doc/website/diagrams/Requesting a Specific Environment.png +0 -0
  93. data/vendor/selenium-grid-1.0.4/doc/website/diagrams/Selenium Grid Logo.graffle +1015 -0
  94. data/vendor/selenium-grid-1.0.4/doc/website/diagrams/Selenium Grid Setup - Small.png +0 -0
  95. data/vendor/selenium-grid-1.0.4/doc/website/diagrams/Selenium Grid Setup.png +0 -0
  96. data/vendor/selenium-grid-1.0.4/doc/website/diagrams/Traditional Selenium Setup - Small.png +0 -0
  97. data/vendor/selenium-grid-1.0.4/doc/website/diagrams/Traditional Selenium Setup.png +0 -0
  98. data/vendor/selenium-grid-1.0.4/doc/website/faq.markdown +686 -0
  99. data/vendor/selenium-grid-1.0.4/doc/website/images/ant_version_osx_screenshot.png +0 -0
  100. data/vendor/selenium-grid-1.0.4/doc/website/images/ant_version_win_screenshot.png +0 -0
  101. data/vendor/selenium-grid-1.0.4/doc/website/images/background_better.png +0 -0
  102. data/vendor/selenium-grid-1.0.4/doc/website/images/background_feedback.png +0 -0
  103. data/vendor/selenium-grid-1.0.4/doc/website/images/background_participate.png +0 -0
  104. data/vendor/selenium-grid-1.0.4/doc/website/images/background_start_tracks.png +0 -0
  105. data/vendor/selenium-grid-1.0.4/doc/website/images/background_started.png +0 -0
  106. data/vendor/selenium-grid-1.0.4/doc/website/images/check_path_osx_screenshot.png +0 -0
  107. data/vendor/selenium-grid-1.0.4/doc/website/images/check_path_win_screenshot.png +0 -0
  108. data/vendor/selenium-grid-1.0.4/doc/website/images/dot_profile_editing_osx_screenshot.png +0 -0
  109. data/vendor/selenium-grid-1.0.4/doc/website/images/dot_profile_osx_screenshot.png +0 -0
  110. data/vendor/selenium-grid-1.0.4/doc/website/images/install/linux/linux-ant-install.png +0 -0
  111. data/vendor/selenium-grid-1.0.4/doc/website/images/install/linux/linux-ant-profile-update.png +0 -0
  112. data/vendor/selenium-grid-1.0.4/doc/website/images/install/linux/linux-ant-verify.png +0 -0
  113. data/vendor/selenium-grid-1.0.4/doc/website/images/install/linux/linux-ant-version.png +0 -0
  114. data/vendor/selenium-grid-1.0.4/doc/website/images/install/linux/linux-java-version.png +0 -0
  115. data/vendor/selenium-grid-1.0.4/doc/website/images/install/linux/linux-navigate-path.png +0 -0
  116. data/vendor/selenium-grid-1.0.4/doc/website/images/install/linux/linux-selenium-install.png +0 -0
  117. data/vendor/selenium-grid-1.0.4/doc/website/images/install/linux/linux-selenium-sanity-check.png +0 -0
  118. data/vendor/selenium-grid-1.0.4/doc/website/images/install/win/selenium-check.bmp +0 -0
  119. data/vendor/selenium-grid-1.0.4/doc/website/images/install_ant_osx_screenshot.png +0 -0
  120. data/vendor/selenium-grid-1.0.4/doc/website/images/installing_grid_osx_screenshot.png +0 -0
  121. data/vendor/selenium-grid-1.0.4/doc/website/images/java_version_osx_screenshot.png +0 -0
  122. data/vendor/selenium-grid-1.0.4/doc/website/images/java_version_win_screenshot.png +0 -0
  123. data/vendor/selenium-grid-1.0.4/doc/website/images/sanity_check_osx_screenshot.png +0 -0
  124. data/vendor/selenium-grid-1.0.4/doc/website/images/sanity_check_win_screenshot.png +0 -0
  125. data/vendor/selenium-grid-1.0.4/doc/website/images/selenium-grid-logo-huge-white.png +0 -0
  126. data/vendor/selenium-grid-1.0.4/doc/website/images/selenium-grid-logo-huge.png +0 -0
  127. data/vendor/selenium-grid-1.0.4/doc/website/images/selenium-grid-logo-large.png +0 -0
  128. data/vendor/selenium-grid-1.0.4/doc/website/images/selenium-grid-logo-small.png +0 -0
  129. data/vendor/selenium-grid-1.0.4/doc/website/images/selenium-grid-logo.png +0 -0
  130. data/vendor/selenium-grid-1.0.4/doc/website/images/selenium_grid_logo_large.png +0 -0
  131. data/vendor/selenium-grid-1.0.4/doc/website/images/update_path_win_screenshot.png +0 -0
  132. data/vendor/selenium-grid-1.0.4/doc/website/javascripts/shadedborder.js +267 -0
  133. data/vendor/selenium-grid-1.0.4/doc/website/stylesheets/document.css +82 -0
  134. data/vendor/selenium-grid-1.0.4/doc/website/stylesheets/faq.css +97 -0
  135. data/vendor/selenium-grid-1.0.4/doc/website/stylesheets/home.css +133 -0
  136. data/vendor/selenium-grid-1.0.4/doc/website/stylesheets/openqa.css +72 -0
  137. data/vendor/selenium-grid-1.0.4/doc/website/stylesheets/site.css +74 -0
  138. data/vendor/selenium-grid-1.0.4/examples/ec2/Capfile +276 -0
  139. data/vendor/selenium-grid-1.0.4/examples/ec2/etc/background.png +0 -0
  140. data/vendor/selenium-grid-1.0.4/examples/ec2/etc/background.svg +163 -0
  141. data/vendor/selenium-grid-1.0.4/examples/ec2/lib/selenium_grid/aws/cloud.rb +35 -0
  142. data/vendor/selenium-grid-1.0.4/examples/ec2/lib/selenium_grid/aws/ec2.rb +7 -0
  143. data/vendor/selenium-grid-1.0.4/examples/ec2/lib/selenium_grid/aws/ec2_client.rb +54 -0
  144. data/vendor/selenium-grid-1.0.4/examples/ec2/lib/selenium_grid/aws/hub.rb +22 -0
  145. data/vendor/selenium-grid-1.0.4/examples/ec2/lib/selenium_grid/aws/remote_command.rb +47 -0
  146. data/vendor/selenium-grid-1.0.4/examples/ec2/lib/selenium_grid/aws/server.rb +56 -0
  147. data/vendor/selenium-grid-1.0.4/examples/ec2/test/unit/all_test.rb +2 -0
  148. data/vendor/selenium-grid-1.0.4/examples/ec2/test/unit/cloud_test.rb +27 -0
  149. data/vendor/selenium-grid-1.0.4/examples/ec2/test/unit/ec2_client_test.rb +137 -0
  150. data/vendor/selenium-grid-1.0.4/examples/ec2/test/unit/hub_test.rb +24 -0
  151. data/vendor/selenium-grid-1.0.4/examples/ec2/test/unit/remote_command_test.rb +46 -0
  152. data/vendor/selenium-grid-1.0.4/examples/ec2/test/unit/server_test.rb +22 -0
  153. data/vendor/selenium-grid-1.0.4/examples/ec2/test/unit/test_helper.rb +4 -0
  154. data/vendor/selenium-grid-1.0.4/examples/ec2/vnc_password +1 -0
  155. data/vendor/selenium-grid-1.0.4/examples/java/Java Example.iml +18 -0
  156. data/vendor/selenium-grid-1.0.4/examples/java/build.xml +90 -0
  157. data/vendor/selenium-grid-1.0.4/examples/java/src/com/thoughtworks/selenium/grid/examples/java/GoogleImageTestBase.java +46 -0
  158. data/vendor/selenium-grid-1.0.4/examples/java/src/com/thoughtworks/selenium/grid/examples/java/ParisTest.java +50 -0
  159. data/vendor/selenium-grid-1.0.4/examples/java/src/com/thoughtworks/selenium/grid/examples/java/PerigordTest.java +42 -0
  160. data/vendor/selenium-grid-1.0.4/examples/java/target/classes/com/thoughtworks/selenium/grid/examples/java/GoogleImageTestBase.class +0 -0
  161. data/vendor/selenium-grid-1.0.4/examples/java/target/classes/com/thoughtworks/selenium/grid/examples/java/ParisTest.class +0 -0
  162. data/vendor/selenium-grid-1.0.4/examples/java/target/classes/com/thoughtworks/selenium/grid/examples/java/PerigordTest.class +0 -0
  163. data/vendor/selenium-grid-1.0.4/examples/java/testng-slow.xml +9 -0
  164. data/vendor/selenium-grid-1.0.4/examples/java/testng.xml +9 -0
  165. data/vendor/selenium-grid-1.0.4/examples/ruby/README +66 -0
  166. data/vendor/selenium-grid-1.0.4/examples/ruby/Rakefile +101 -0
  167. data/vendor/selenium-grid-1.0.4/examples/ruby/Ruby Example.iml +17 -0
  168. data/vendor/selenium-grid-1.0.4/examples/ruby/flickr_example.rb +16 -0
  169. data/vendor/selenium-grid-1.0.4/examples/ruby/lib/array_extension.rb +13 -0
  170. data/vendor/selenium-grid-1.0.4/examples/ruby/lib/multi_process_behaviour_runner.rb +28 -0
  171. data/vendor/selenium-grid-1.0.4/examples/ruby/paris_spec.rb +34 -0
  172. data/vendor/selenium-grid-1.0.4/examples/ruby/perigord_spec.rb +22 -0
  173. data/vendor/selenium-grid-1.0.4/examples/ruby/spec_helper.rb +59 -0
  174. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_04b8969da99c51289f692b41abbf271b_page_screenshot.png +0 -0
  175. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_04b8969da99c51289f692b41abbf271b_system_screenshot.png +0 -0
  176. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_280fd974268e3aecb89fbfbee25b5322_page_screenshot.png +0 -0
  177. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_280fd974268e3aecb89fbfbee25b5322_system_screenshot.png +0 -0
  178. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_8808fb9026e023f809d50ddc9cf00cd3_page_screenshot.png +0 -0
  179. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_8808fb9026e023f809d50ddc9cf00cd3_system_screenshot.png +0 -0
  180. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_94b209474d36add5ba908f308c63aa15_page_screenshot.png +0 -0
  181. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_94b209474d36add5ba908f308c63aa15_system_screenshot.png +0 -0
  182. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_a18dd8ce90cb4681d55b2148326ff085_page_screenshot.png +0 -0
  183. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_a18dd8ce90cb4681d55b2148326ff085_system_screenshot.png +0 -0
  184. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_b877a400a718a915c95038427389e0d9_page_screenshot.png +0 -0
  185. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_b877a400a718a915c95038427389e0d9_system_screenshot.png +0 -0
  186. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_c1c6e8109e89867b52f6e123b8847b85_page_screenshot.png +0 -0
  187. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_c1c6e8109e89867b52f6e123b8847b85_system_screenshot.png +0 -0
  188. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_c9e7156818e496f6abb983a9a1725295_page_screenshot.png +0 -0
  189. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_c9e7156818e496f6abb983a9a1725295_system_screenshot.png +0 -0
  190. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_d6b2848186a7e4a73e19692c0fab2ae5_page_screenshot.png +0 -0
  191. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_d6b2848186a7e4a73e19692c0fab2ae5_system_screenshot.png +0 -0
  192. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_e30337afe445f0b6ebd29ecfaf4cd9f0_page_screenshot.png +0 -0
  193. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_e30337afe445f0b6ebd29ecfaf4cd9f0_system_screenshot.png +0 -0
  194. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_edc2da92cbf119e95eae988bb6f80792_page_screenshot.png +0 -0
  195. data/vendor/selenium-grid-1.0.4/examples/ruby/tmp/resources/test_report/example_edc2da92cbf119e95eae988bb6f80792_system_screenshot.png +0 -0
  196. data/vendor/selenium-grid-1.0.4/grid_configuration.yml +46 -0
  197. data/vendor/selenium-grid-1.0.4/lib/build/common-build.xml +228 -0
  198. data/vendor/selenium-grid-1.0.4/lib/ruby/file_extensions.rb +9 -0
  199. data/vendor/selenium-grid-1.0.4/lib/ruby/java/classpath.rb +28 -0
  200. data/vendor/selenium-grid-1.0.4/lib/ruby/java/vm.rb +31 -0
  201. data/vendor/selenium-grid-1.0.4/lib/ruby/s_grid/hub.rb +29 -0
  202. data/vendor/selenium-grid-1.0.4/lib/ruby/s_grid/remote_control.rb +40 -0
  203. data/vendor/selenium-grid-1.0.4/lib/ruby/tcp_socket_extensions.rb +23 -0
  204. data/vendor/selenium-grid-1.0.4/lib/selenium-grid-demo-1.0.4.jar +0 -0
  205. data/vendor/selenium-grid-1.0.4/lib/selenium-grid-demo-standalone-1.0.4.jar +0 -0
  206. data/vendor/selenium-grid-1.0.4/lib/selenium-grid-hub-1.0.4.jar +0 -0
  207. data/vendor/selenium-grid-1.0.4/lib/selenium-grid-hub-standalone-1.0.4.jar +0 -0
  208. data/vendor/selenium-grid-1.0.4/lib/selenium-grid-remote-control-1.0.4.jar +0 -0
  209. data/vendor/selenium-grid-1.0.4/lib/selenium-grid-remote-control-standalone-1.0.4.jar +0 -0
  210. data/vendor/selenium-grid-1.0.4/lib/selenium-grid-tools-1.0.4.jar +0 -0
  211. data/vendor/selenium-grid-1.0.4/lib/selenium-grid-tools-standalone-1.0.4.jar +0 -0
  212. data/vendor/selenium-grid-1.0.4/lib/testng.policy +11 -0
  213. data/vendor/selenium-grid-1.0.4/log/test.txt +1 -0
  214. data/vendor/selenium-grid-1.0.4/project.properties +4 -0
  215. data/vendor/selenium-grid-1.0.4/sample-scripts/kill-rcs.sh +3 -0
  216. data/vendor/selenium-grid-1.0.4/sample-scripts/launch-rc.sh +4 -0
  217. data/vendor/selenium-grid-1.0.4/sample-scripts/launch-rcs.sh +5 -0
  218. data/vendor/selenium-grid-1.0.4/sample-scripts/launch-remote-controls.rb +20 -0
  219. data/vendor/selenium-grid-1.0.4/target/reports/Selenium Grid Demo In Parallel/Command line test.html +218 -0
  220. data/vendor/selenium-grid-1.0.4/target/reports/Selenium Grid Demo In Parallel/classes.html +44 -0
  221. data/vendor/selenium-grid-1.0.4/target/reports/Selenium Grid Demo In Parallel/groups.html +5 -0
  222. data/vendor/selenium-grid-1.0.4/target/reports/Selenium Grid Demo In Parallel/index.html +6 -0
  223. data/vendor/selenium-grid-1.0.4/target/reports/Selenium Grid Demo In Parallel/main.html +2 -0
  224. data/vendor/selenium-grid-1.0.4/target/reports/Selenium Grid Demo In Parallel/methods-alphabetical.html +12 -0
  225. data/vendor/selenium-grid-1.0.4/target/reports/Selenium Grid Demo In Parallel/methods-not-run.html +2 -0
  226. data/vendor/selenium-grid-1.0.4/target/reports/Selenium Grid Demo In Parallel/methods.html +12 -0
  227. data/vendor/selenium-grid-1.0.4/target/reports/Selenium Grid Demo In Parallel/reporter-output.html +1 -0
  228. data/vendor/selenium-grid-1.0.4/target/reports/Selenium Grid Demo In Parallel/testng.xml.html +1 -0
  229. data/vendor/selenium-grid-1.0.4/target/reports/Selenium Grid Demo In Parallel/toc.html +30 -0
  230. data/vendor/selenium-grid-1.0.4/target/reports/emailable-report.html +117 -0
  231. data/vendor/selenium-grid-1.0.4/target/reports/index.html +9 -0
  232. data/vendor/selenium-grid-1.0.4/vendor/commons-logging-1.0.4.jar +0 -0
  233. data/vendor/selenium-grid-1.0.4/vendor/selenium-java-client-driver-1.0.1.jar +0 -0
  234. data/vendor/selenium-grid-1.0.4/vendor/selenium-server-1.0.3.jar +0 -0
  235. data/vendor/selenium-grid-1.0.4/vendor/testng-5.7-jdk15.jar +0 -0
  236. metadata +296 -0
@@ -0,0 +1,24 @@
1
+ require File.dirname(__FILE__) + "/test_helper"
2
+
3
+ unit_tests do
4
+
5
+ test "url return the public url where the hub can be contacted" do
6
+ hub = SeleniumGrid::AWS::Hub.new nil
7
+ hub.public_dns = "public.dns"
8
+ assert_equal "http://public.dns:4444", hub.url
9
+ end
10
+
11
+ test "private_url return the private url where the hub can be contacted" do
12
+ hub = SeleniumGrid::AWS::Hub.new nil
13
+ hub.private_dns = "private.dns"
14
+ assert_equal "http://private.dns:4444", hub.private_url
15
+ end
16
+
17
+ test "console_url return the public url of the hub console" do
18
+ hub = SeleniumGrid::AWS::Hub.new nil
19
+ hub.public_dns = "public.dns"
20
+ assert_equal "http://public.dns:4444/console", hub.console_url
21
+ end
22
+
23
+
24
+ end
@@ -0,0 +1,46 @@
1
+ require File.dirname(__FILE__) + "/test_helper"
2
+
3
+ unit_tests do
4
+
5
+ test "ssh_command builds ssh based command targetting the host" do
6
+ command = SeleniumGrid::AWS::RemoteCommand.new "ls", :host => "the.host"
7
+ assert_equal "ssh root@the.host", command.ssh_command
8
+ end
9
+
10
+ test "ssh_command use custom key when keypair options is provided" do
11
+ command = SeleniumGrid::AWS::RemoteCommand.new "ls",
12
+ :host => "the.host", :keypair => "/the/key.pair"
13
+ assert_equal "ssh -i '/the/key.pair' root@the.host", command.ssh_command
14
+ end
15
+
16
+ test "remote_command" do
17
+ command = SeleniumGrid::AWS::RemoteCommand.new "ls", :pwd => "/a/directory"
18
+ assert_equal "cd '/a/directory'; ls", command.remote_command
19
+ end
20
+
21
+ test "remote_command set path when path is provided as an option" do
22
+ command = SeleniumGrid::AWS::RemoteCommand.new "ls", :path => "/a/directory:and/another"
23
+ assert_equal "PATH=/a/directory:and/another:${PATH}; export PATH; ls", command.remote_command
24
+ end
25
+
26
+ test "remote_command set display when display is provided as an option" do
27
+ command = SeleniumGrid::AWS::RemoteCommand.new "ls", :display => ":0"
28
+ assert_equal "DISPLAY=:0; export DISPLAY; ls", command.remote_command
29
+ end
30
+
31
+ test "full_command execute the remote command using ssh_command" do
32
+ command = SeleniumGrid::AWS::RemoteCommand.new nil
33
+ command.stubs(:ssh_command).returns("the_ssh_command")
34
+ command.stubs(:remote_command).returns("the remote command")
35
+ assert_equal "the_ssh_command 'the remote command'", command.full_command
36
+ end
37
+
38
+ test "full_command wraps remote_command with 'su user -c' when su option is set" do
39
+ command = SeleniumGrid::AWS::RemoteCommand.new nil, :su => "a-user"
40
+ command.stubs(:ssh_command).returns("the_ssh_command")
41
+ command.stubs(:remote_command).returns("the remote command")
42
+ assert_equal "the_ssh_command \"su -l a-user -c 'the remote command'\"",
43
+ command.full_command
44
+ end
45
+
46
+ end
@@ -0,0 +1,22 @@
1
+ require File.dirname(__FILE__) + "/test_helper"
2
+
3
+ unit_tests do
4
+
5
+ test "refresh_status updates public dns" do
6
+ server = SeleniumGrid::AWS::Server.new :an_instance_id
7
+ SeleniumGrid::AWS::Server.expects(:describe).with(:an_instance_id).
8
+ returns(:public_dns => :new_public_dns)
9
+ server.refresh_status
10
+ assert_equal :new_public_dns, server.public_dns
11
+ end
12
+
13
+ test "refresh_status updates private dns" do
14
+ server = SeleniumGrid::AWS::Server.new :an_instance_id
15
+ SeleniumGrid::AWS::Server.expects(:describe).with(:an_instance_id).
16
+ returns(:private_dns => :new_private_dns)
17
+ server.refresh_status
18
+ assert_equal :new_private_dns, server.private_dns
19
+ end
20
+
21
+
22
+ end
@@ -0,0 +1,4 @@
1
+ require File.dirname(__FILE__) + "/../../lib/selenium_grid/aws/ec2"
2
+ require "rubygems"
3
+ require "dust"
4
+ require "mocha"
@@ -0,0 +1 @@
1
+ ����YI
@@ -0,0 +1,18 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <module relativePaths="true" type="JAVA_MODULE" version="4">
3
+ <component name="NewModuleRootManager" inherit-compiler-output="true">
4
+ <exclude-output />
5
+ <content url="file://$MODULE_DIR$">
6
+ <sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
7
+ </content>
8
+ <orderEntry type="inheritedJdk" />
9
+ <orderEntry type="sourceFolder" forTests="false" />
10
+ <orderEntry type="library" name="Selenium Java Client Driver" level="project" />
11
+ <orderEntry type="library" name="TestNG" level="project" />
12
+ <orderEntry type="module" module-name="Tools" />
13
+ </component>
14
+ <component name="RSpecModuleSettingsStorage">
15
+ <RSPEC_MODULE_SETTINGS_STORAGE_ID NAME="RSPEC_SUPPORT_TYPE" VALUE="NONE" />
16
+ </component>
17
+ </module>
18
+
@@ -0,0 +1,90 @@
1
+ <project name="Selenium Grid Java Example" default="run" basedir=".">
2
+
3
+ <description>Selenium Grid Java Example</description>
4
+
5
+ <property name="rootdir" value="${basedir}/../.."/>
6
+ <property file="${rootdir}/project.properties"/>
7
+ <property name="name" value="Selenium Grid Demo"/>
8
+ <property name="artifact" value="selenium-grid-demo"/>
9
+ <property name="version" value="SNAPSHOT"/>
10
+ <property name="selenium.version" value="SET ME"/>
11
+
12
+ <property name="build.src" location="src"/>
13
+
14
+ <import file="${rootdir}/lib/build/common-build.xml" />
15
+
16
+ <property name="webSite" value="http://images.google.com" />
17
+ <property name="seleniumHost" value="localhost" />
18
+ <property name="seleniumPort" value="4444" />
19
+ <property name="browser" value="*firefox" />
20
+
21
+ <path id="compile.classpath">
22
+ <fileset dir="${rootdir}/vendor">
23
+ <include name="selenium-java-client-driver-${selenium.version}.jar"/>
24
+ <include name="testng-5.7-jdk15.jar"/>
25
+ <include name="commons-logging-1.0.4.jar"/>
26
+ </fileset>
27
+ <pathelement location="${rootdir}/tools/target/classes"/>
28
+ <pathelement location="${rootdir}/tools/target/dist/lib/selenium-grid-tools-standalone-${version}.jar"/>
29
+ <pathelement location="${rootdir}/lib/selenium-grid-tools-standalone-${version}.jar"/>
30
+ <pathelement path="${java.class.path}/"/>
31
+ </path>
32
+
33
+ <path id="runtime.classpath">
34
+ <path refid="compile.classpath"/>
35
+ <pathelement path="${build.output}/"/>
36
+ </path>
37
+
38
+ <target name="run" depends="compile" description="Run Selenium tests in parallel (20 threads)">
39
+ <echo>${seleniumHost}</echo>
40
+ <java classpathref="runtime.classpath"
41
+ classname="org.testng.TestNG"
42
+ failonerror="true">
43
+
44
+ <sysproperty key="java.security.policy" file="${rootdir}/lib/testng.policy"/>
45
+ <sysproperty key="webSite" value="${webSite}" />
46
+ <sysproperty key="seleniumHost" value="${seleniumHost}" />
47
+ <sysproperty key="seleniumPort" value="${seleniumPort}" />
48
+ <sysproperty key="browser" value="${browser}" />
49
+ <arg value="-d" />
50
+ <arg value="${basedir}/target/reports" />
51
+ <arg value="-suitename" />
52
+ <arg value="Selenium Grid Java Sample Test Suite" />
53
+ <arg value="-parallel"/>
54
+ <arg value="methods"/>
55
+ <arg value="-threadcount"/>
56
+ <arg value="15"/>
57
+ <arg value="testng.xml"/>
58
+ </java>
59
+
60
+ </target>
61
+
62
+ <target name="run-in-sequence" depends="compile" description="Run Selenium tests in sequence">
63
+ <echo>${seleniumHost}</echo>
64
+ <java classpathref="runtime.classpath"
65
+ classname="org.testng.TestNG"
66
+ failonerror="true">
67
+
68
+ <sysproperty key="java.security.policy" file="${rootdir}/lib/testng.policy"/>
69
+ <sysproperty key="webSite" value="${webSite}" />
70
+ <sysproperty key="seleniumHost" value="${seleniumHost}" />
71
+ <sysproperty key="seleniumPort" value="${seleniumPort}" />
72
+ <sysproperty key="browser" value="${browser}" />
73
+ <arg value="-d" />
74
+ <arg value="${basedir}/target/reports" />
75
+ <arg value="-suitename" />
76
+ <arg value="Selenium Grid Java Sample Test Suite" />
77
+ <arg value="-parallel"/>
78
+ <arg value="methods"/>
79
+ <arg value="-threadcount"/>
80
+ <arg value="20"/>
81
+ <arg value="testng-slow.xml"/>
82
+ </java>
83
+
84
+ </target>
85
+
86
+ <target name="build" depends="compile"/>
87
+ <target name="dist" depends="build"/>
88
+ <target name="coverage-analysis" />
89
+
90
+ </project>
@@ -0,0 +1,46 @@
1
+ package com.thoughtworks.selenium.grid.examples.java;
2
+
3
+ import static com.thoughtworks.selenium.grid.tools.ThreadSafeSeleniumSessionStorage.closeSeleniumSession;
4
+ import static com.thoughtworks.selenium.grid.tools.ThreadSafeSeleniumSessionStorage.session;
5
+ import static com.thoughtworks.selenium.grid.tools.ThreadSafeSeleniumSessionStorage.startSeleniumSession;
6
+ import static org.testng.AssertJUnit.assertTrue;
7
+ import org.testng.annotations.AfterMethod;
8
+ import org.testng.annotations.BeforeMethod;
9
+ import org.testng.annotations.Parameters;
10
+
11
+
12
+ /**
13
+ * Base class for all tests in Selenium Grid Java examples.
14
+ */
15
+ public class GoogleImageTestBase {
16
+
17
+ public static final String TIMEOUT = "120000";
18
+
19
+ @BeforeMethod(groups = {"default", "example"}, alwaysRun = true)
20
+ @Parameters({"seleniumHost", "seleniumPort", "browser", "webSite"})
21
+ protected void startSession(String seleniumHost, int seleniumPort, String browser, String webSite) throws Exception {
22
+ startSeleniumSession(seleniumHost, seleniumPort, browser, webSite);
23
+ session().setTimeout(TIMEOUT);
24
+ }
25
+
26
+ @AfterMethod(groups = {"default", "example"}, alwaysRun = true)
27
+ protected void closeSession() throws Exception {
28
+ closeSeleniumSession();
29
+ }
30
+
31
+ protected void runFlickrScenario(String searchString) {
32
+ session().open("/");
33
+ assertTrue(session().getLocation(), session().getLocation().contains("images.google.com"));
34
+ session().type("q", searchString);
35
+ session().click("btnG");
36
+ session().waitForPageToLoad(TIMEOUT);
37
+ session().click("link=Advanced Image Search");
38
+ session().waitForPageToLoad(TIMEOUT);
39
+ session().click("rimgtype4");
40
+ session().click("sf");
41
+ session().select("imgc", "full color");
42
+ session().click("btnG");
43
+ session().waitForPageToLoad(TIMEOUT);
44
+ }
45
+
46
+ }
@@ -0,0 +1,50 @@
1
+ package com.thoughtworks.selenium.grid.examples.java;
2
+
3
+ import org.testng.annotations.Test;
4
+
5
+
6
+ /**
7
+ */
8
+ public class ParisTest extends GoogleImageTestBase {
9
+
10
+ @Test(groups = {"example", "firefox", "default"}, description = "Louvre")
11
+ public void louvre() throws Throwable {
12
+ runFlickrScenario("Louvre");
13
+ }
14
+
15
+ @Test(groups = {"example", "firefox", "default"}, description = "Louvre")
16
+ public void rubinius() throws Throwable {
17
+ runFlickrScenario("Louvre");
18
+ }
19
+
20
+ @Test(groups = {"example", "firefox", "default"}, description = "Pont Neuf")
21
+ public void pontNeuf() throws Throwable {
22
+ runFlickrScenario("Pont Neuf");
23
+ }
24
+
25
+ @Test(groups = {"example", "firefox", "default"}, description = "Notre Dame de Paris")
26
+ public void notreDameDeParis() throws Throwable {
27
+ runFlickrScenario("Notre Dame de Paris");
28
+ }
29
+
30
+ @Test(groups = {"example", "firefox", "default"}, description = "Versailles")
31
+ public void versailles() throws Throwable {
32
+ runFlickrScenario("Versailles");
33
+ }
34
+
35
+ @Test(groups = {"example", "firefox", "default"}, description = "Seine by Night")
36
+ public void seine() throws Throwable {
37
+ runFlickrScenario("Seine by Night");
38
+ }
39
+
40
+ @Test(groups = {"example", "firefox", "default"}, description = "Tour Eiffel")
41
+ public void tourEiffel() throws Throwable {
42
+ runFlickrScenario("Tour Eiffel");
43
+ }
44
+
45
+ @Test(groups = {"example", "firefox", "default"}, description = "Avenue des Champs Elysees")
46
+ public void champsElysees() throws Throwable {
47
+ runFlickrScenario("Avenue des Champs Elysees");
48
+ }
49
+
50
+ }
@@ -0,0 +1,42 @@
1
+ package com.thoughtworks.selenium.grid.examples.java;
2
+
3
+ import org.testng.annotations.Test;
4
+
5
+
6
+ /**
7
+ */
8
+ public class PerigordTest extends GoogleImageTestBase {
9
+
10
+
11
+ @Test(groups = {"example", "firefox", "default"}, description = "Lascaux Hall of the Bull")
12
+ public void rubinius() throws Throwable {
13
+ runFlickrScenario("Lascaux Hall of the Bull");
14
+ }
15
+
16
+ @Test(groups = {"example", "firefox", "default"}, description = "Sarlat")
17
+ public void pontNeuf() throws Throwable {
18
+ runFlickrScenario("Sarlat");
19
+ }
20
+
21
+ @Test(groups = {"example", "firefox", "default"}, description = "Cathedral in Perigueux")
22
+ public void notreDameDeParis() throws Throwable {
23
+ runFlickrScenario("Cathedral in Perigueux");
24
+ }
25
+
26
+ @Test(groups = {"example", "firefox", "default"}, description = "Montbazillac")
27
+ public void versailles() throws Throwable {
28
+ runFlickrScenario("Montbazillac");
29
+ }
30
+
31
+ @Test(groups = {"example", "firefox", "default"}, description = "Domme - La Halle Fleurie")
32
+ public void domme() throws Throwable {
33
+ runFlickrScenario("Domme - La Halle Fleurie");
34
+ }
35
+
36
+ @Test(groups = {"example", "firefox", "default"}, description = "Rouffignac")
37
+ public void rouffignac() throws Throwable {
38
+ runFlickrScenario("Rouffignac");
39
+ }
40
+
41
+
42
+ }
@@ -0,0 +1,9 @@
1
+ <!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd" >
2
+
3
+ <suite name="Selenium Grid Java Sample Test Suite" verbose="3" >
4
+ <test name="Selenium Grid Java Sample Tests" >
5
+ <packages>
6
+ <package name="com.thoughtworks.selenium.grid.examples.java" />
7
+ </packages>
8
+ </test>
9
+ </suite>
@@ -0,0 +1,9 @@
1
+ <!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd" >
2
+
3
+ <suite name="Selenium Grid Java Sample Test Suite" parallel="methods" thread-count="7" verbose="3" >
4
+ <test name="Selenium Grid Java Sample Tests" >
5
+ <packages>
6
+ <package name="com.thoughtworks.selenium.grid.examples.java" />
7
+ </packages>
8
+ </test>
9
+ </suite>
@@ -0,0 +1,66 @@
1
+ Example using RSpec based web acceptance tests
2
+
3
+ This example demonstrates how to run tests in parallel to take advantage
4
+ of Selenium Grid functionalities.
5
+
6
+ Getting Ready
7
+ -------------
8
+
9
+ To run this example you will need:
10
+
11
+ * Have a valid Ruby install: http://www.ruby-lang.org
12
+ * Have RubyGems installed : http://rubygems.org
13
+ * Install the RSpec gem : `sudo gem install rspec`
14
+ This example has been tested with RSpec 1.0.8
15
+ * Install the Spec UI gem : `sudo gem install spec_ui`
16
+ Spec UI provides some nice reporting for Selenium tests
17
+
18
+ You are probably better off running this example on Mac OS X or another
19
+ UNIX platform. Be prepared to get your hands dirty if you run this on
20
+ Windows, this has not been tested yet.
21
+
22
+
23
+ Running the Tests
24
+ -----------------
25
+
26
+ To run the tests you must first launch a Selenium Hub and 4 Selenium
27
+ remote controls as explained in the Demo:
28
+ http://seleniumhq.org/selenium-grid/run_the_demo.html
29
+
30
+ You can then:
31
+
32
+ * Run the tests in sequence:
33
+
34
+ $ rake run_in_sequence
35
+
36
+ * Run the tests in parallel using Brian Takita's Multi-threaded runner:
37
+ (only guaranted to work with RSpec 1.0.8 r2338)
38
+
39
+ $ rake run_in_parallel_single_process
40
+
41
+ * Run the tests in parallel spawning multiple processes:
42
+
43
+ $ rake run_in_parallel
44
+
45
+
46
+ Note that for a realistic web acceptance test suite, running tests in
47
+ parallel using Ruby green threads does not scale very well so I recommend
48
+ using the multi-process runner in real life. The multi-threaded runner is
49
+ very cool though, and should scale well with JRuby.
50
+
51
+ For now only RSpec behaviours, not RSpec examples run in parallel
52
+ (i.e files, not tests). We are working on a better solution that can
53
+ efficiently run RSpec examples in parallel.
54
+
55
+ Reporting
56
+ ---------
57
+
58
+ This example also demonstrate how to get some pretty cool reporting
59
+ based on Spec UI. This is very useful to troubleshoot failures
60
+ when your web acceptance build turns red: You get screenshots and HTML
61
+ capture of the current page when a test fails. Pretty cool when tests are
62
+ distributed using Selenium Grid! Make sure to take a look at the ./report
63
+ directory after running `rake run_in_parallel`. Even better: change a
64
+ specification so that a test fails, launch `rake run_in_parallel` and
65
+ look at the new aggregated report.
66
+