integrity 0.1.9 → 0.1.9.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (199) hide show
  1. data/Rakefile +57 -31
  2. data/config/heroku/.gems +4 -0
  3. data/config/heroku/Rakefile +6 -0
  4. data/config/heroku/config.ru +7 -0
  5. data/config/heroku/integrity-config.rb +11 -0
  6. data/integrity.gemspec +123 -0
  7. data/lib/integrity.rb +7 -14
  8. data/lib/integrity/installer.rb +45 -35
  9. data/lib/integrity/notifier/test.rb +59 -0
  10. data/lib/integrity/notifier/test/fixtures.rb +108 -0
  11. data/lib/integrity/notifier/test/hpricot_matcher.rb +38 -0
  12. data/test/acceptance/build_notifications_test.rb +2 -2
  13. data/test/acceptance/installer_test.rb +25 -7
  14. data/test/helpers.rb +1 -1
  15. data/test/helpers/acceptance.rb +1 -4
  16. data/test/helpers/fixtures.rb +0 -22
  17. data/test/unit/notifier/test_test.rb +29 -0
  18. data/test/unit/project_builder_test.rb +4 -1
  19. data/vendor/sinatra-ditties/README.rdoc +3 -0
  20. data/vendor/sinatra-ditties/lib/sinatra/ditties.rb +12 -0
  21. data/vendor/sinatra-ditties/lib/sinatra/ditties/authorization.rb +61 -0
  22. data/vendor/sinatra-ditties/lib/sinatra/ditties/mailer.rb +146 -0
  23. metadata +79 -318
  24. data/VERSION.yml +0 -4
  25. data/config/config.ru +0 -29
  26. data/config/config.yml +0 -34
  27. data/lib/integrity/notifier/test_helpers.rb +0 -100
  28. data/vendor/webrat/History.txt +0 -306
  29. data/vendor/webrat/MIT-LICENSE.txt +0 -19
  30. data/vendor/webrat/README.rdoc +0 -85
  31. data/vendor/webrat/Rakefile +0 -151
  32. data/vendor/webrat/install.rb +0 -1
  33. data/vendor/webrat/lib/webrat.rb +0 -34
  34. data/vendor/webrat/lib/webrat/core.rb +0 -14
  35. data/vendor/webrat/lib/webrat/core/configuration.rb +0 -98
  36. data/vendor/webrat/lib/webrat/core/elements/area.rb +0 -31
  37. data/vendor/webrat/lib/webrat/core/elements/element.rb +0 -33
  38. data/vendor/webrat/lib/webrat/core/elements/field.rb +0 -403
  39. data/vendor/webrat/lib/webrat/core/elements/form.rb +0 -103
  40. data/vendor/webrat/lib/webrat/core/elements/label.rb +0 -31
  41. data/vendor/webrat/lib/webrat/core/elements/link.rb +0 -90
  42. data/vendor/webrat/lib/webrat/core/elements/select_option.rb +0 -35
  43. data/vendor/webrat/lib/webrat/core/locators.rb +0 -20
  44. data/vendor/webrat/lib/webrat/core/locators/area_locator.rb +0 -38
  45. data/vendor/webrat/lib/webrat/core/locators/button_locator.rb +0 -54
  46. data/vendor/webrat/lib/webrat/core/locators/field_by_id_locator.rb +0 -37
  47. data/vendor/webrat/lib/webrat/core/locators/field_labeled_locator.rb +0 -56
  48. data/vendor/webrat/lib/webrat/core/locators/field_locator.rb +0 -25
  49. data/vendor/webrat/lib/webrat/core/locators/field_named_locator.rb +0 -41
  50. data/vendor/webrat/lib/webrat/core/locators/form_locator.rb +0 -19
  51. data/vendor/webrat/lib/webrat/core/locators/label_locator.rb +0 -34
  52. data/vendor/webrat/lib/webrat/core/locators/link_locator.rb +0 -66
  53. data/vendor/webrat/lib/webrat/core/locators/locator.rb +0 -20
  54. data/vendor/webrat/lib/webrat/core/locators/select_option_locator.rb +0 -59
  55. data/vendor/webrat/lib/webrat/core/logging.rb +0 -21
  56. data/vendor/webrat/lib/webrat/core/matchers.rb +0 -4
  57. data/vendor/webrat/lib/webrat/core/matchers/have_content.rb +0 -73
  58. data/vendor/webrat/lib/webrat/core/matchers/have_selector.rb +0 -74
  59. data/vendor/webrat/lib/webrat/core/matchers/have_tag.rb +0 -21
  60. data/vendor/webrat/lib/webrat/core/matchers/have_xpath.rb +0 -147
  61. data/vendor/webrat/lib/webrat/core/methods.rb +0 -61
  62. data/vendor/webrat/lib/webrat/core/mime.rb +0 -29
  63. data/vendor/webrat/lib/webrat/core/save_and_open_page.rb +0 -50
  64. data/vendor/webrat/lib/webrat/core/scope.rb +0 -350
  65. data/vendor/webrat/lib/webrat/core/session.rb +0 -281
  66. data/vendor/webrat/lib/webrat/core/xml.rb +0 -115
  67. data/vendor/webrat/lib/webrat/core/xml/hpricot.rb +0 -19
  68. data/vendor/webrat/lib/webrat/core/xml/nokogiri.rb +0 -76
  69. data/vendor/webrat/lib/webrat/core/xml/rexml.rb +0 -24
  70. data/vendor/webrat/lib/webrat/core_extensions/blank.rb +0 -58
  71. data/vendor/webrat/lib/webrat/core_extensions/deprecate.rb +0 -8
  72. data/vendor/webrat/lib/webrat/core_extensions/detect_mapped.rb +0 -12
  73. data/vendor/webrat/lib/webrat/core_extensions/meta_class.rb +0 -6
  74. data/vendor/webrat/lib/webrat/core_extensions/nil_to_param.rb +0 -5
  75. data/vendor/webrat/lib/webrat/mechanize.rb +0 -74
  76. data/vendor/webrat/lib/webrat/merb.rb +0 -9
  77. data/vendor/webrat/lib/webrat/merb_session.rb +0 -65
  78. data/vendor/webrat/lib/webrat/rack.rb +0 -24
  79. data/vendor/webrat/lib/webrat/rails.rb +0 -105
  80. data/vendor/webrat/lib/webrat/rspec-rails.rb +0 -13
  81. data/vendor/webrat/lib/webrat/selenium.rb +0 -154
  82. data/vendor/webrat/lib/webrat/selenium/location_strategy_javascript/button.js +0 -12
  83. data/vendor/webrat/lib/webrat/selenium/location_strategy_javascript/label.js +0 -16
  84. data/vendor/webrat/lib/webrat/selenium/location_strategy_javascript/webrat.js +0 -5
  85. data/vendor/webrat/lib/webrat/selenium/location_strategy_javascript/webratlink.js +0 -9
  86. data/vendor/webrat/lib/webrat/selenium/location_strategy_javascript/webratlinkwithin.js +0 -15
  87. data/vendor/webrat/lib/webrat/selenium/location_strategy_javascript/webratselectwithoption.js +0 -5
  88. data/vendor/webrat/lib/webrat/selenium/matchers.rb +0 -4
  89. data/vendor/webrat/lib/webrat/selenium/matchers/have_content.rb +0 -66
  90. data/vendor/webrat/lib/webrat/selenium/matchers/have_selector.rb +0 -49
  91. data/vendor/webrat/lib/webrat/selenium/matchers/have_tag.rb +0 -72
  92. data/vendor/webrat/lib/webrat/selenium/matchers/have_xpath.rb +0 -45
  93. data/vendor/webrat/lib/webrat/selenium/selenium_extensions.js +0 -6
  94. data/vendor/webrat/lib/webrat/selenium/selenium_session.rb +0 -247
  95. data/vendor/webrat/lib/webrat/sinatra.rb +0 -44
  96. data/vendor/webrat/spec/fakes/test_session.rb +0 -34
  97. data/vendor/webrat/spec/integration/merb/Rakefile +0 -35
  98. data/vendor/webrat/spec/integration/merb/app/controllers/application.rb +0 -2
  99. data/vendor/webrat/spec/integration/merb/app/controllers/exceptions.rb +0 -13
  100. data/vendor/webrat/spec/integration/merb/app/controllers/testing.rb +0 -18
  101. data/vendor/webrat/spec/integration/merb/app/views/exceptions/not_acceptable.html.erb +0 -63
  102. data/vendor/webrat/spec/integration/merb/app/views/exceptions/not_found.html.erb +0 -47
  103. data/vendor/webrat/spec/integration/merb/app/views/layout/application.html.erb +0 -12
  104. data/vendor/webrat/spec/integration/merb/app/views/testing/show_form.html.erb +0 -27
  105. data/vendor/webrat/spec/integration/merb/config/environments/development.rb +0 -15
  106. data/vendor/webrat/spec/integration/merb/config/environments/rake.rb +0 -11
  107. data/vendor/webrat/spec/integration/merb/config/environments/test.rb +0 -14
  108. data/vendor/webrat/spec/integration/merb/config/init.rb +0 -25
  109. data/vendor/webrat/spec/integration/merb/config/rack.rb +0 -11
  110. data/vendor/webrat/spec/integration/merb/config/router.rb +0 -33
  111. data/vendor/webrat/spec/integration/merb/spec/spec.opts +0 -1
  112. data/vendor/webrat/spec/integration/merb/spec/spec_helper.rb +0 -24
  113. data/vendor/webrat/spec/integration/merb/spec/webrat_spec.rb +0 -32
  114. data/vendor/webrat/spec/integration/merb/tasks/merb.thor/app_script.rb +0 -31
  115. data/vendor/webrat/spec/integration/merb/tasks/merb.thor/common.rb +0 -64
  116. data/vendor/webrat/spec/integration/merb/tasks/merb.thor/gem_ext.rb +0 -124
  117. data/vendor/webrat/spec/integration/merb/tasks/merb.thor/main.thor +0 -150
  118. data/vendor/webrat/spec/integration/merb/tasks/merb.thor/ops.rb +0 -93
  119. data/vendor/webrat/spec/integration/merb/tasks/merb.thor/utils.rb +0 -40
  120. data/vendor/webrat/spec/integration/rails/Rakefile +0 -30
  121. data/vendor/webrat/spec/integration/rails/app/controllers/application.rb +0 -15
  122. data/vendor/webrat/spec/integration/rails/app/controllers/webrat_controller.rb +0 -39
  123. data/vendor/webrat/spec/integration/rails/app/views/webrat/before_redirect_form.html.erb +0 -4
  124. data/vendor/webrat/spec/integration/rails/app/views/webrat/form.html.erb +0 -28
  125. data/vendor/webrat/spec/integration/rails/config/boot.rb +0 -109
  126. data/vendor/webrat/spec/integration/rails/config/environment.rb +0 -12
  127. data/vendor/webrat/spec/integration/rails/config/environments/development.rb +0 -17
  128. data/vendor/webrat/spec/integration/rails/config/environments/selenium.rb +0 -22
  129. data/vendor/webrat/spec/integration/rails/config/environments/test.rb +0 -22
  130. data/vendor/webrat/spec/integration/rails/config/initializers/inflections.rb +0 -10
  131. data/vendor/webrat/spec/integration/rails/config/initializers/mime_types.rb +0 -5
  132. data/vendor/webrat/spec/integration/rails/config/initializers/new_rails_defaults.rb +0 -17
  133. data/vendor/webrat/spec/integration/rails/config/locales/en.yml +0 -5
  134. data/vendor/webrat/spec/integration/rails/config/routes.rb +0 -14
  135. data/vendor/webrat/spec/integration/rails/public/404.html +0 -30
  136. data/vendor/webrat/spec/integration/rails/public/422.html +0 -30
  137. data/vendor/webrat/spec/integration/rails/public/500.html +0 -33
  138. data/vendor/webrat/spec/integration/rails/script/about +0 -4
  139. data/vendor/webrat/spec/integration/rails/script/console +0 -3
  140. data/vendor/webrat/spec/integration/rails/script/dbconsole +0 -3
  141. data/vendor/webrat/spec/integration/rails/script/destroy +0 -3
  142. data/vendor/webrat/spec/integration/rails/script/generate +0 -3
  143. data/vendor/webrat/spec/integration/rails/script/performance/benchmarker +0 -3
  144. data/vendor/webrat/spec/integration/rails/script/performance/profiler +0 -3
  145. data/vendor/webrat/spec/integration/rails/script/performance/request +0 -3
  146. data/vendor/webrat/spec/integration/rails/script/plugin +0 -3
  147. data/vendor/webrat/spec/integration/rails/script/process/inspector +0 -3
  148. data/vendor/webrat/spec/integration/rails/script/process/reaper +0 -3
  149. data/vendor/webrat/spec/integration/rails/script/process/spawner +0 -3
  150. data/vendor/webrat/spec/integration/rails/script/runner +0 -3
  151. data/vendor/webrat/spec/integration/rails/script/server +0 -3
  152. data/vendor/webrat/spec/integration/rails/test/integration/webrat_test.rb +0 -80
  153. data/vendor/webrat/spec/integration/rails/test/test_helper.rb +0 -25
  154. data/vendor/webrat/spec/integration/sinatra/Rakefile +0 -5
  155. data/vendor/webrat/spec/integration/sinatra/classic_app.rb +0 -64
  156. data/vendor/webrat/spec/integration/sinatra/modular_app.rb +0 -16
  157. data/vendor/webrat/spec/integration/sinatra/test/classic_app_test.rb +0 -37
  158. data/vendor/webrat/spec/integration/sinatra/test/modular_app_test.rb +0 -18
  159. data/vendor/webrat/spec/integration/sinatra/test/test_helper.rb +0 -16
  160. data/vendor/webrat/spec/private/core/configuration_spec.rb +0 -104
  161. data/vendor/webrat/spec/private/core/field_spec.rb +0 -67
  162. data/vendor/webrat/spec/private/core/link_spec.rb +0 -24
  163. data/vendor/webrat/spec/private/core/logging_spec.rb +0 -10
  164. data/vendor/webrat/spec/private/core/session_spec.rb +0 -198
  165. data/vendor/webrat/spec/private/mechanize/mechanize_session_spec.rb +0 -81
  166. data/vendor/webrat/spec/private/merb/merb_session_spec.rb +0 -42
  167. data/vendor/webrat/spec/private/nokogiri_spec.rb +0 -77
  168. data/vendor/webrat/spec/private/rails/attaches_file_spec.rb +0 -81
  169. data/vendor/webrat/spec/private/rails/rails_session_spec.rb +0 -110
  170. data/vendor/webrat/spec/private/selenium/selenium_session_spec.rb +0 -44
  171. data/vendor/webrat/spec/private/selenium/selenium_spec.rb +0 -109
  172. data/vendor/webrat/spec/public/basic_auth_spec.rb +0 -24
  173. data/vendor/webrat/spec/public/check_spec.rb +0 -191
  174. data/vendor/webrat/spec/public/choose_spec.rb +0 -118
  175. data/vendor/webrat/spec/public/click_area_spec.rb +0 -106
  176. data/vendor/webrat/spec/public/click_button_spec.rb +0 -502
  177. data/vendor/webrat/spec/public/click_link_spec.rb +0 -469
  178. data/vendor/webrat/spec/public/fill_in_spec.rb +0 -209
  179. data/vendor/webrat/spec/public/locators/field_by_xpath_spec.rb +0 -19
  180. data/vendor/webrat/spec/public/locators/field_labeled_spec.rb +0 -157
  181. data/vendor/webrat/spec/public/locators/field_with_id_spec.rb +0 -16
  182. data/vendor/webrat/spec/public/matchers/contain_spec.rb +0 -114
  183. data/vendor/webrat/spec/public/matchers/have_selector_spec.rb +0 -135
  184. data/vendor/webrat/spec/public/matchers/have_tag_spec.rb +0 -39
  185. data/vendor/webrat/spec/public/matchers/have_xpath_spec.rb +0 -123
  186. data/vendor/webrat/spec/public/reload_spec.rb +0 -10
  187. data/vendor/webrat/spec/public/save_and_open_spec.rb +0 -51
  188. data/vendor/webrat/spec/public/select_date_spec.rb +0 -88
  189. data/vendor/webrat/spec/public/select_datetime_spec.rb +0 -106
  190. data/vendor/webrat/spec/public/select_spec.rb +0 -246
  191. data/vendor/webrat/spec/public/select_time_spec.rb +0 -79
  192. data/vendor/webrat/spec/public/set_hidden_field_spec.rb +0 -5
  193. data/vendor/webrat/spec/public/submit_form_spec.rb +0 -5
  194. data/vendor/webrat/spec/public/visit_spec.rb +0 -58
  195. data/vendor/webrat/spec/public/within_spec.rb +0 -177
  196. data/vendor/webrat/spec/rcov.opts +0 -1
  197. data/vendor/webrat/spec/spec.opts +0 -2
  198. data/vendor/webrat/spec/spec_helper.rb +0 -50
  199. data/vendor/webrat/vendor/selenium-server.jar +0 -0
data/config/config.ru DELETED
@@ -1,29 +0,0 @@
1
- #!/usr/bin/env ruby
2
- require File.dirname(__FILE__) + "/../lib/integrity"
3
- require "rack/lobster"
4
- # If you want to add any notifiers, install the gems and then require them here
5
- # For example, to enable the Email notifier: install the gem (from github:
6
- #
7
- # sudo gem install -s http://gems.github.com foca-integrity-email
8
- #
9
- # And then uncomment the following line:
10
- #
11
- # require "notifier/email"
12
-
13
- # Load configuration and initialize Integrity
14
- Integrity.new#(File.dirname(__FILE__) + "/config.yml")
15
- DataMapper.auto_migrate!
16
-
17
- # You probably don't want to edit anything below
18
- Integrity::App.set :environment, ENV["RACK_ENV"] || :production
19
- Integrity::App.set :port, 8910
20
- rack = proc do |env|
21
- [200, { 'Content-Type' => 'text/html' }, "#{env['rack.session'].inspect}"]
22
- end
23
-
24
- map "/foo" do
25
- run Integrity::App
26
- end
27
- map "/" do
28
- run rack
29
- end
data/config/config.yml DELETED
@@ -1,34 +0,0 @@
1
- # Domain where integrity will be running from. This is used to have
2
- # nice URLs in your notifications.
3
- # For example:
4
- # http://builder.integrityapp.com
5
- :base_uri: http://0.0.0.0:1234
6
-
7
- # This should be a complete connection string to your database. For example
8
- # `mysql://user@localhost/integrity` (you need an `integrity` db created in
9
- # localhost, of course).
10
- :database_uri: sqlite3:///home/simon/tmp/integrity.db
11
-
12
- # This is where your project's code will be checked out to. Make sure it's
13
- # writable by the user that runs Integrity.
14
- :export_directory: /home/simon/tmp/integrity_exports
15
-
16
- # Path to the integrity log file
17
- :log: /tmp/integrity.log
18
-
19
- # Enable or disable HTTP authentication for the app. BE AWARE that if you
20
- # disable this anyone can delete and alter projects, so do it only if your
21
- # app is running in a controlled environment (ie, behind your company's
22
- # firewall.)
23
- :use_basic_auth: false
24
-
25
- # When `use_basic_auth` is true, the admin's username for HTTP authentication.
26
- :admin_username: username
27
-
28
- # When `use_basic_auth` is true, the admin's password. Usually saved as a
29
- # SHA1 hash. See the next option.
30
- :admin_password: a94a8fe5ccb19ba61c4c0873d391e987982fbbd3
31
-
32
- # If this is true, then whenever we authenticate the admin user, will hash
33
- # it using SHA1. If not, we'll assume the provided password is in plain text.
34
- :hash_admin_password: true
@@ -1,100 +0,0 @@
1
- require "hpricot"
2
- require "haml"
3
- require File.dirname(__FILE__) + "/../../integrity"
4
-
5
- module Integrity
6
- class Notifier
7
- module TestHelpers
8
- module HpricotAssertions
9
- # Thanks Harry! http://gist.github.com/39960
10
-
11
- class HpricotMatcher
12
- def initialize(html)
13
- @doc = Hpricot(html)
14
- end
15
-
16
- # elements('h1') returns a Hpricot::Elements object with all h1-tags.
17
- def elements(selector)
18
- @doc.search(selector)
19
- end
20
-
21
- # element('h1') returns Hpricot::Elem with first h1-tag, or nil if
22
- # none exist.
23
- def element(selector)
24
- @doc.at(selector)
25
- end
26
-
27
- # tags('h1') returns the inner HTML of all matched elements mathed.
28
- def tags(selector)
29
- e = elements(selector)
30
- e.map {|x| x.inner_html}
31
- end
32
-
33
- # tag('h1') returns the inner HTML of the first mached element, or
34
- # nil if none matched.
35
- def tag(selector)
36
- e = element(selector)
37
- e && e.inner_html
38
- end
39
- end
40
-
41
- def assert_have_tag(html, selector, content=nil)
42
- matcher = HpricotMatcher.new(html)
43
- assert_equal content, matcher.tag(selector) if content
44
- assert matcher.tag(selector)
45
- end
46
- end
47
-
48
- module NotifierFormHelpers
49
- include HpricotAssertions
50
-
51
- def form(config={})
52
- Haml::Engine.new(notifier_class.to_haml).
53
- render(OpenStruct.new(:config => config))
54
- end
55
-
56
- def assert_form_have_tag(selector, options={})
57
- content = options.delete(:content)
58
- assert_have_tag(form(options), selector, content)
59
- end
60
-
61
- def assert_form_have_option(option, value=nil)
62
- selector = "input##{notifier.downcase}_notifier_#{option}"
63
- selector << "[@name='notifiers[#{notifier}][#{option}]']"
64
- selector << "[@value='#{value}']" if value
65
-
66
- assert_form_have_tag(selector, option => value)
67
- end
68
-
69
- def assert_form_have_options(*options)
70
- options.each { |option| assert_form_have_option(option) }
71
- end
72
- end
73
-
74
- include NotifierFormHelpers
75
-
76
- def build
77
- @build ||= Integrity::Build.gen(:successful)
78
- end
79
-
80
- def commit
81
- @commit ||= build.commit
82
- end
83
-
84
- def notifier_class
85
- Integrity::Notifier.const_get(notifier)
86
- end
87
-
88
- def notification
89
- notifier_class.new(commit).body
90
- end
91
-
92
- def setup_database
93
- DataMapper.setup(:default, "sqlite3::memory:")
94
- DataMapper.auto_migrate!
95
-
96
- require File.dirname(__FILE__) + "/../../../test/helpers/fixtures"
97
- end
98
- end
99
- end
100
- end
@@ -1,306 +0,0 @@
1
- == Git (Unreleased)
2
-
3
- * Minor enhancements
4
-
5
- * Support for "modular" Sinatra app style (Simon Rozet)
6
- * When faced with a label with no for attribute, that contains a hidden field
7
- and another field, as can be the case in Rails 2.3's checkbox view,
8
- webrat now locates the non-hidden field. (Luke Melia)
9
- * When using Rails 2.3, use Rack::Utils to parse params (Matthew Ford)
10
- * Initial Merb and Sinatra compatibility for Selenium mode (Corey Donohoe)
11
- * Add application_framework config for Selenium mode to determine how to
12
- start and stop the app server (Corey Donohoe)
13
-
14
- * Bug fixes
15
-
16
- * Fix following of absolute redirect URL in Sinatra (Simon Rozet)
17
-
18
- == 0.4.2 / 2009-02-24
19
-
20
- * Major enhancements
21
-
22
- * Significant improvements to have_selector. It now supports specifying
23
- attributes in a hash and :count and :content options. See
24
- have_selector_spec.rb for more.
25
- * Add the same functionality mentioned above to have_xpath
26
-
27
- * Minor enhancements
28
-
29
- * Squeeze extra whitespace out of failures messages from contain
30
- matcher
31
- * Detect infinite redirects and raise a Webrat::InfiniteRedirectError
32
- (Daniel Lucraft)
33
-
34
- * Bug fixes
35
-
36
- * Properly quote single and double quotes strings in XPath
37
- * Fix warning caused by Nokogiri deprecating CSS::Parser.parse
38
- (Aaron Patterson)
39
- * Accept do/end blocks in matchers. [#157] (Peter Jaros)
40
- * Quote --chdir option to mongrel_rails to support RAILS_ROOTs with spaces
41
- (T.J. VanSlyke)
42
-
43
- == 0.4.1 / 2009-01-31
44
-
45
- * Minor enhancements
46
-
47
- * Support Sinatra 0.9 (Harry Vangberg)
48
- * Update query param parsing to work with latest Edge Rails
49
- * Added #redirected_to method to easily check where an external redirect was
50
- redirected to (Adam Greene)
51
- * Recognize input tags with type button (Lena Herrmann)
52
- * Add uncheck method to Selenium mode (Lee Bankewitz)
53
-
54
- * Bug fixes
55
-
56
- * Make requests to a Rails app using a full URL instead of a relative path. This change
57
- is helpful for Rails apps that use subdomains. (John Hwang and Zach Dennis)
58
- * Follow redirects that are on the same domain but a different subdomain
59
- (Adam Greene)
60
- * rescue from Webrat::TimeoutError in selenium matchers which allows NegativeMatchers
61
- to behave correctly (Noah Davis)
62
- * Switch to using selenium.click instead of .check when checking a checkbox
63
- (Noah Davis)
64
- * Create tmp/pids directory if directory does not exist. (Amos King and Mike Gaffney)
65
- * Setup deprecated writers for the selenium_environment= and selenium_port= config
66
- * Ensure the previous pages params aren't passed through redirect (Daniel Lucraft and
67
- Bryan Helmkamp)
68
- * Labels should only search for fields within the current scope (Kyle Hargraves)
69
-
70
- == 0.4.0 / 2009-01-18
71
-
72
- * _IMPORTANT_ Breaking change:
73
-
74
- * Removed init.rb auto-require of webrat/rails
75
- * Removed auto-require of webrat/rails when requiring webrat when RAILS_ENV is
76
- defined
77
-
78
- In your env.rb or test_helper.rb file, ensure you have something like:
79
-
80
- require "webrat"
81
-
82
- Webrat.configure do |config|
83
- config.mode = :rails
84
- end
85
-
86
- * Major enhancements
87
-
88
- * Major improvements to Webrat::Selenium (Many contributors listed here)
89
- * Add assert_* methods for using Webrat's matchers w/o RSpec (Mike Gaffney, Amos King)
90
- * Added Webrat.configure method for Webrat configuration [#33] (Mike Gaffney)
91
- * Added select_time, select_date, and select_datetime to API. [#36] (Ben Mabey)
92
- * Use Hpricot and REXML when not parsing with Nokogiri (on JRuby, for example)
93
-
94
- * Minor enhancements
95
-
96
- * Added Selenium grid configuration and support. (Amos King && Cornel Borcean)
97
- * Support passing an ActiveRecord model to #within when in Rails mode [#68] (Luke Melia)
98
- * Make assert_* matchers in rails mode increment the assertions count [#123] (Amos King)
99
- * Added assert_* matchers to selenium matchers [#110] (Amos King)
100
- * Added assert_contain, assert_not_contain [#86] (Mike Gaffney, Amos King)
101
- * Add configuration options for the Selenium environment and port (Kieran Pilkington)
102
- * Maximize the browser window after initializing Selenium (Luke Melia)
103
- * Better inspect output for Webrat elements
104
- * Sets the Webrat mode with Configuration#mode= in the config block [#85] (Mike Gaffney)
105
- * Detect if the document is XML or HTML using the Content-Type when in Rails mode
106
- * Expose #selenium method for direct access to Selenium client
107
- * Check nokogiri gem version before requiring nokogiri
108
- * Include the Selenium server jar file in the gem (Bryan Helmkamp, Ben Schwarz)
109
- * Added key_down, key_up and fire_event to Selenium session (Fernando Garcia)
110
- * Fix outputing README during Rails plugin install (Fernando Garcia)
111
- * Strip newlines when matching label text (Miha Filej)
112
- * Add simple support for accessing Webrat's matchers from RSpec by requiring
113
- "webrat/rspec-rails" (David Chelimsky)
114
- * Support save_and_open_page in Windows and Cygwin (Mike Gaffney)
115
- * Added RadioField#checked? to indicated whether or not a radio button is checked
116
- (Luke Melia)
117
- * Add spec:jruby rake task for running Webrat's spec suite with JRuby
118
- * Added field_by_xpath to locate a Webrat::Field using arbitrary XPath expressions
119
- * Helpful error message for missing option values [#40] (Ben Mabey)
120
- * Add set_hidden_field method (Noah Davis, Bryan Helmkamp)
121
- * Add submit_form method for submitting a form by ID (Noah Davis, Bryan Helmkamp)
122
- * Switch to using Nokogiri.parse for simple XML/XHTML autodetection [#66]
123
- * Removed Webrat.root method, which seemed to be unused
124
- * Added automatic starting and stopping of the Selenium server and a Mongrel Rails
125
- app server when using webrat/selenium
126
- * Switch to using selenium-client gem and vendor selenium-server.jar (Luke Melia)
127
- * Added gemspec so the gem builds on GitHub now
128
- * Deprecate old style methods (fills_in is deprecated in favor of fill_in, etc.)
129
- * Improvements to the README and RDoc (Bryan Helmkamp, Mike Gaffney)
130
- * Allow clicking links by id and id regexp (Mike Gaffney)
131
- * Raise Webrat::DisabledFieldError when attempting to manipulate a disabled field
132
- * Raise Webrat::NotFoundErrors when an element is not found
133
- * Raise Webrat::PageLoadError when a failure occurs so that application exceptions
134
- can be more accurately tested (Ryan Briones)
135
- * Helpful error message for missing option in select box. [#40] (Ben Mabey)
136
- * Extracted save_and_open page to make it usable in Selenium mode (Luke Melia)
137
- * Added save_and_open_screengrab for Selenium mode (Luke Melia)
138
-
139
- * Bug fixes
140
-
141
- * field_labeled should disregard labels without matching fields (Kyle Hargraves)
142
- * Fixed bug where Scope was creating a new DOM rather than re-using the existing DOM.
143
- [#105] (Zach Dennis)
144
- * Support Rails > v2.2 by using ActionController::RequestParser for param parsing [#107]
145
- (Marcello Nuccio)
146
- * Raise a Webrat::NotFoundError if the scope passed to #within doesn't exist [#90]
147
- * Match against link _text_ which decodes character references.
148
- Useful for multibyte languages like Japanese (moronatural@gmail.com)
149
- * Fix params hash generation for Mechanize when Merb is not defined [#62]
150
- * Expose some Webrat methods that were missing from the Webrat::Methods module
151
- (Low Chin Chau)
152
- * Allow mechanize session to pass through basic auth (Ryan Briones)
153
- * Improvements to the Mechanize support (Jeremy Burks)
154
- * Fix following fully qualified local links (Lawrence Pit)
155
- * Fixed bug where Webrat would lose complex parameters (like foo[bar[baz]][])
156
- in Merb due to not correctly merging Mashes. (Drew Colthorp)
157
- * Extend Rails' ActionController::IntegrationTest instead of
158
- ActionController::Integration::Session (Fixes using Webrat's #select method and
159
- avoids usage of method_missing)
160
- * Ensure that Webrat::MechanizeSession.request_page always uses an absolute
161
- URL. (Graham Ashton)
162
- * Strip anchor tags from URIs before passing to Rails integration session
163
- (Noah Davis)
164
- * Treat text and regexp when matching Selenium buttons (Ross Kaffenberger)
165
- * Allow SeleniumSession's click_button to be called without an argument without
166
- blowing up (Luke Melia)
167
-
168
- == 0.3.4 / 2008-12-29
169
-
170
- * 1 Minor enhancement
171
-
172
- * Fix compatibility with Nokogiri 1.1.0 on JRuby
173
-
174
- * 1 Bug fix
175
-
176
- * Correct version for Nokogiri dependency in gem
177
-
178
- == 0.3.3 / 2008-12-28
179
-
180
- * 1 Minor enhancement
181
-
182
- * Fix compatibility with Nokogiri 1.1.0 on MRI
183
-
184
- == 0.3.2 / 2008-11-08
185
-
186
- * 1 Minor enhancement
187
-
188
- * Fixes behavior or have_tag when a block is passed. It passes the matched node(s)
189
- to the block for further specs again. (Carl Lerche)
190
-
191
- == 0.3.1 / 2008-11-07
192
-
193
- * 1 Minor enhancement
194
-
195
- * Use @_webrat_session instance variable instead of @session for Merb integration
196
- to avoid collisions
197
-
198
- == 0.3.0 / 2008-11-07
199
-
200
- * 4 Major enhancements
201
-
202
- * Added Merb support (Gwyn Morfey, Jeremy Burks, Rob Kaufman, Yehuda Katz)
203
- * Added experimental Selenium support (Luke Melia)
204
- * Add have_selector, have_xpath, have_tag and contain matchers from Merb
205
- * Switch from Hpricot to Nokogiri for XML parsing (thanks, Aaron Patterson)
206
-
207
- * 37 Minor enhancements
208
-
209
- * Added #within for manipulating the current page within a selector scope
210
- * Add support for file fields via #attaches_file method (Rails only at the moment)
211
- (Kyle Hargraves)
212
- * Add support for simulating SSL requests (Luke Melia)
213
- * Added #basic_auth(user, pass) to support HTTP Basic Auth (Aslak Hellesøy)
214
- * Added support for Sinatra and Rack (Aslak Hellesøy)
215
- * Rename visits to visit, fills_in to fill_in, etc.
216
- * Add #field_labeled for looking up form fields by label (David Chelimsky)
217
- * Add #field_named and #field_with_id locators
218
- * Don't depend on hoe anymore
219
- * Return responses after sending requests
220
- * Allow clicking links and buttons by a regular expression in Selenium (Luke Melia)
221
- * Allow clicking links by a regular expression
222
- * Add #http_accept for including MIME type HTTP "Accept" headers (Ryan Briones)
223
- * Add #header to support inclusion of custom HTTP headers (Ryan Briones)
224
- * Consider response codes 200-499 as successful enough to not raise a Webrat error
225
- (David Leal)
226
- * Add support for clicking areas of an image map (Alex Lang)
227
- * Support relative links, including href="?foo=bar" (Kyle Hargraves)
228
- * Separated Rails-specific code from the Webrat core to make it easier to use
229
- Webrat with other environments
230
- * Alias visits as visit, clicks_link as click_link, etc. for better readability
231
- * Raise error when trying to interact with a disabled form element (Luke Melia)
232
- * Don't send disabled form elements to the server (Nicholas A. Evans)
233
- * Display response body when the page load is not successful (David Leal)
234
- * CGI escape form field values (Miha Filej)
235
- * Add support for redirect_to :back by sending HTTP_REFERER headers
236
- (Hendrik Volkmer)
237
- * Expose current DOM (as an Hpricot object) as #current_dom
238
- * Add support for disabling JavaScript when clicking a link to enable testing of
239
- both JS and non-JS implementations (Luke Melia and Bryan Helmkamp)
240
- * Support &nbsp's as spaces in matching link text (Luke Melia)
241
- * Support button elements (Nick Sieger)
242
- * Support matching select options by regexp (Kyle Hargraves)
243
- * save_and_open_page rewrites css and image references to provide a friendlier
244
- debugging experience (Luke Melia)
245
- * Added support for matching alt attributes in fields (primarly for clicks_button)
246
- (Aaron Quint)
247
- * Support '&amp;' in submitted values (Kyle Hargraves)
248
- * Support clicking links by title (Dan Barry)
249
- * Added missing spec for clicking image buttons (Tim Harper)
250
- * Switched tests to specs, and from Mocha to RSpec's mocking library
251
- * Add support to click_button for IDs (Gwyn Morfey)
252
- * Miscellaneous core refactorings (Jan Suchal)
253
-
254
- * 8 Bug fixes
255
-
256
- * Fix initialization of WWW::Mechanize (Derek Kastner)
257
- * Don't open blank pages in the browser (Kyle Hargraves)
258
- * Support radio buttons with multiple labels (Dan Barry)
259
- * Fix load order bug on some platforms (Ismael Celis)
260
- * Fix bug with empty select list option (Kyle Hargraves)
261
- * Fix regression of not sending default values in password fields
262
- * Don't explode if encountering inputs with no type attribute (assume text)
263
- * Fix bug where choosing a radio button in a series with a default submitted the
264
- incorrect field value (Luke Melia)
265
-
266
- == 0.2.0 / 2008-04-04
267
-
268
- * 4 Major enhancements
269
-
270
- * Add save_and_open_page to aid in debugging
271
- * Add radio button support via #chooses method
272
- * Add basic support for Rails-generated JavaScript link tags
273
- * Add support for checkboxes (Patches from Kyle Hargraves and Jarkko Laine)
274
- * Add support for textarea fields (Sacha Schlegel)
275
-
276
- * 8 Minor enhancements
277
-
278
- * Added reloads method to reload the page (Kamal Fariz Mahyuddi)
279
- * Prevent making a request if clicking on local anchor link (Kamal Fariz Mahyuddi)
280
- * Added clicks_link_within(selector, link_text), allowing restricting link search
281
- to within a given css selector (Luke Melia)
282
- * Allow specifying the input name/label when doing a select (David Chelimsky)
283
- * Raise a specific exception if the developer tries to manipulate form elements
284
- before loading a page (James Deville)
285
- * Add support for alternate POST, PUT and DELETE link clicking (Kyle Hargraves)
286
- * Change clicks_link to find the shortest matching link (Luke Melia)
287
- * Improve matching for labels in potentially ambiguous cases
288
-
289
- * 7 Bug fixes
290
-
291
- * Fix incorrect serializing of collection inputs, i.e. name contains []
292
- (Kamal Fariz Mahyuddi)
293
- * Serialize empty text field values just like browsers (Kamal Fariz Mahyuddi)
294
- * Quick fix to avoid @dom not initialized warnings (Kamal Fariz Mahyuddi)
295
- * Docfix: bad reference to #select method in README (Luke Melia)
296
- * Ensure Rails-style checkboxes work properly (checkboxes followed by a hidden
297
- input with the same name)
298
- * Fix Edge Rails (a.k.a. 2.0 RC) compatibility (David Chelimsky)
299
- * Support param hashes nested more than one level (David Chelimsky)
300
-
301
- == 0.1.0 / 2007-11-28
302
-
303
- * 1 major enhancement
304
-
305
- * Birthday!
306
-