Permalink
Browse files

Fixed errors and warnings related to Rails 3

  • Loading branch information...
1 parent 207ace9 commit b1b6ac40c3f429d06dd3bb3fd720f15c18aacdb3 @jferris jferris committed Jun 7, 2010
Showing with 10,007 additions and 122 deletions.
  1. +2 −1 .gitignore
  2. +7 −3 Rakefile
  3. +1 −5 lib/shoulda/action_controller/matchers/assign_to_matcher.rb
  4. +18 −1 lib/shoulda/action_controller/matchers/filter_param_matcher.rb
  5. +1 −1 lib/shoulda/action_controller/matchers/render_template_matcher.rb
  6. +33 −15 lib/shoulda/action_controller/matchers/render_with_layout_matcher.rb
  7. +1 −1 lib/shoulda/action_controller/matchers/respond_with_content_type_matcher.rb
  8. +5 −1 lib/shoulda/action_controller/matchers/respond_with_matcher.rb
  9. +1 −1 lib/shoulda/action_controller/matchers/route_matcher.rb
  10. +5 −1 lib/shoulda/action_controller/matchers/set_session_matcher.rb
  11. +1 −1 lib/shoulda/action_controller/matchers/set_the_flash_matcher.rb
  12. +6 −1 lib/shoulda/active_record/helpers.rb
  13. +10 −2 lib/shoulda/active_record/matchers/allow_value_matcher.rb
  14. +0 −4 lib/shoulda/rails.rb
  15. +1 −0 rails/init.rb
  16. +1 −1 test/functional/posts_controller_test.rb
  17. +1 −1 test/functional/users_controller_test.rb
  18. +16 −5 test/matchers/action_mailer/have_sent_email_test.rb
  19. +1 −1 test/matchers/active_record/allow_mass_assignment_of_matcher_test.rb
  20. +1 −1 test/matchers/active_record/allow_value_matcher_test.rb
  21. +16 −16 test/matchers/active_record/association_matcher_test.rb
  22. +3 −2 test/matchers/active_record/ensure_inclusion_of_matcher_test.rb
  23. +1 −1 test/matchers/active_record/ensure_length_of_matcher_test.rb
  24. +1 −1 test/matchers/active_record/have_db_column_matcher_test.rb
  25. +1 −1 test/matchers/active_record/have_db_index_matcher_test.rb
  26. +1 −1 test/matchers/active_record/have_readonly_attributes_matcher_test.rb
  27. +1 −1 test/matchers/active_record/validate_acceptance_of_matcher_test.rb
  28. +1 −1 test/matchers/active_record/validate_format_of_matcher_test.rb
  29. +1 −1 test/matchers/active_record/validate_numericality_of_matcher_test.rb
  30. +1 −1 test/matchers/active_record/validate_presence_of_matcher_test.rb
  31. +1 −1 test/matchers/active_record/validate_uniqueness_of_matcher_test.rb
  32. +1 −1 test/matchers/controller/assign_to_matcher_test.rb
  33. +10 −2 test/matchers/controller/filter_param_matcher_test.rb
  34. +1 −1 test/matchers/controller/redirect_to_matcher_test.rb
  35. +1 −1 test/matchers/controller/render_template_matcher_test.rb
  36. +15 −2 test/matchers/controller/render_with_layout_matcher_test.rb
  37. +1 −1 test/matchers/controller/respond_with_content_type_matcher_test.rb
  38. +1 −11 test/matchers/controller/respond_with_matcher_test.rb
  39. +1 −1 test/matchers/controller/route_matcher_test.rb
  40. +1 −1 test/matchers/controller/set_session_matcher_test.rb
  41. +1 −1 test/matchers/controller/set_the_flash_matcher.rb
  42. +1 −1 test/other/autoload_macro_test.rb
  43. +1 −1 test/other/context_test.rb
  44. +1 −1 test/other/helpers_test.rb
  45. +1 −1 test/other/private_helpers_test.rb
  46. +1 −1 test/other/should_test.rb
  47. +2 −2 test/{model_builder.rb → rails2_model_builder.rb}
  48. 0 test/{rails_root → rails2_root}/app/controllers/application_controller.rb
  49. 0 test/{rails_root → rails2_root}/app/controllers/posts_controller.rb
  50. 0 test/{rails_root → rails2_root}/app/controllers/users_controller.rb
  51. 0 test/{rails_root → rails2_root}/app/helpers/application_helper.rb
  52. 0 test/{rails_root → rails2_root}/app/helpers/posts_helper.rb
  53. 0 test/{rails_root → rails2_root}/app/helpers/users_helper.rb
  54. 0 test/{rails_root → rails2_root}/app/models/address.rb
  55. 0 test/{rails_root → rails2_root}/app/models/flea.rb
  56. 0 test/{rails_root → rails2_root}/app/models/friendship.rb
  57. 0 test/{rails_root → rails2_root}/app/models/pets/cat.rb
  58. 0 test/{rails_root → rails2_root}/app/models/pets/dog.rb
  59. 0 test/{rails_root → rails2_root}/app/models/post.rb
  60. 0 test/{rails_root → rails2_root}/app/models/product.rb
  61. 0 test/{rails_root → rails2_root}/app/models/profile.rb
  62. 0 test/{rails_root → rails2_root}/app/models/registration.rb
  63. 0 test/{rails_root → rails2_root}/app/models/tag.rb
  64. 0 test/{rails_root → rails2_root}/app/models/tagging.rb
  65. 0 test/{rails_root → rails2_root}/app/models/treat.rb
  66. 0 test/{rails_root → rails2_root}/app/models/user.rb
  67. 0 test/{rails_root → rails2_root}/app/views/layouts/posts.rhtml
  68. 0 test/{rails_root → rails2_root}/app/views/layouts/users.rhtml
  69. 0 test/{rails_root → rails2_root}/app/views/layouts/wide.html.erb
  70. 0 test/{rails_root → rails2_root}/app/views/posts/edit.rhtml
  71. 0 test/{rails_root → rails2_root}/app/views/posts/index.rhtml
  72. 0 test/{rails_root → rails2_root}/app/views/posts/new.rhtml
  73. 0 test/{rails_root → rails2_root}/app/views/posts/show.rhtml
  74. 0 test/{rails_root → rails2_root}/app/views/users/edit.rhtml
  75. 0 test/{rails_root → rails2_root}/app/views/users/index.rhtml
  76. 0 test/{rails_root → rails2_root}/app/views/users/new.rhtml
  77. 0 test/{rails_root → rails2_root}/app/views/users/show.rhtml
  78. 0 test/{rails_root → rails2_root}/config/boot.rb
  79. 0 test/{rails_root → rails2_root}/config/database.yml
  80. +0 −1 test/{rails_root → rails2_root}/config/environment.rb
  81. 0 test/{rails_root → rails2_root}/config/environments/test.rb
  82. 0 test/{rails_root → rails2_root}/config/initializers/new_rails_defaults.rb
  83. 0 test/{rails_root → rails2_root}/config/initializers/shoulda.rb
  84. 0 test/{rails_root → rails2_root}/config/routes.rb
  85. 0 test/{rails_root → rails2_root}/db/migrate/001_create_users.rb
  86. 0 test/{rails_root → rails2_root}/db/migrate/002_create_posts.rb
  87. 0 test/{rails_root → rails2_root}/db/migrate/003_create_taggings.rb
  88. 0 test/{rails_root → rails2_root}/db/migrate/004_create_tags.rb
  89. 0 test/{rails_root → rails2_root}/db/migrate/005_create_dogs.rb
  90. 0 test/{rails_root → rails2_root}/db/migrate/006_create_addresses.rb
  91. 0 test/{rails_root → rails2_root}/db/migrate/007_create_fleas.rb
  92. 0 test/{rails_root → rails2_root}/db/migrate/008_create_dogs_fleas.rb
  93. 0 test/{rails_root → rails2_root}/db/migrate/009_create_products.rb
  94. 0 test/{rails_root → rails2_root}/db/migrate/010_create_friendships.rb
  95. 0 test/{rails_root → rails2_root}/db/migrate/011_create_treats.rb
  96. 0 test/{rails_root → rails2_root}/db/migrate/20090506203502_create_profiles.rb
  97. 0 test/{rails_root → rails2_root}/db/migrate/20090506203536_create_registrations.rb
  98. 0 test/{rails_root → rails2_root}/db/migrate/20090513104502_create_cats.rb
  99. 0 test/{rails_root → rails2_root}/db/schema.rb
  100. 0 test/{rails_root → rails2_root}/log/.keep
  101. 0 test/{rails_root → rails2_root}/public/.htaccess
  102. 0 test/{rails_root → rails2_root}/public/404.html
  103. 0 test/{rails_root → rails2_root}/public/422.html
  104. 0 test/{rails_root → rails2_root}/public/500.html
  105. 0 test/{rails_root → rails2_root}/script/console
  106. 0 test/{rails_root → rails2_root}/script/generate
  107. 0 test/{rails_root → rails2_root}/test/shoulda_macros/custom_macro.rb
  108. 0 test/{rails_root → rails2_root}/vendor/gems/gem_with_macro-0.0.1/shoulda_macros/gem_macro.rb
  109. 0 test/{rails_root → rails2_root}/vendor/plugins/.keep
  110. 0 test/{rails_root → rails2_root}/vendor/plugins/plugin_with_macro/shoulda_macros/plugin_macro.rb
  111. +6 −0 test/rails2_test_helper.rb
  112. +118 −0 test/rails3_model_builder.rb
  113. +4 −0 test/rails3_root/.gitignore
  114. +28 −0 test/rails3_root/Gemfile
  115. +244 −0 test/rails3_root/README
  116. +10 −0 test/rails3_root/Rakefile
  117. +22 −0 test/rails3_root/app/controllers/application_controller.rb
  118. +87 −0 test/rails3_root/app/controllers/posts_controller.rb
  119. +82 −0 test/rails3_root/app/controllers/users_controller.rb
  120. +2 −0 test/rails3_root/app/helpers/application_helper.rb
  121. +7 −0 test/rails3_root/app/models/address.rb
  122. +3 −0 test/rails3_root/app/models/flea.rb
  123. +4 −0 test/rails3_root/app/models/friendship.rb
  124. +7 −0 test/rails3_root/app/models/pets/cat.rb
  125. +10 −0 test/rails3_root/app/models/pets/dog.rb
  126. +12 −0 test/rails3_root/app/models/post.rb
  127. +12 −0 test/rails3_root/app/models/product.rb
  128. +2 −0 test/rails3_root/app/models/profile.rb
  129. +2 −0 test/rails3_root/app/models/registration.rb
  130. +8 −0 test/rails3_root/app/models/tag.rb
  131. +4 −0 test/rails3_root/app/models/tagging.rb
  132. +3 −0 test/rails3_root/app/models/treat.rb
  133. +32 −0 test/rails3_root/app/models/user.rb
  134. +14 −0 test/rails3_root/app/views/layouts/application.html.erb
  135. +19 −0 test/rails3_root/app/views/layouts/posts.rhtml
  136. +17 −0 test/rails3_root/app/views/layouts/users.rhtml
  137. +1 −0 test/rails3_root/app/views/layouts/wide.html.erb
  138. +27 −0 test/rails3_root/app/views/posts/edit.rhtml
  139. +25 −0 test/rails3_root/app/views/posts/index.rhtml
  140. +24 −0 test/rails3_root/app/views/posts/new.rhtml
  141. +18 −0 test/rails3_root/app/views/posts/show.rhtml
  142. +22 −0 test/rails3_root/app/views/users/edit.rhtml
  143. +22 −0 test/rails3_root/app/views/users/index.rhtml
  144. +21 −0 test/rails3_root/app/views/users/new.rhtml
  145. +13 −0 test/rails3_root/app/views/users/show.rhtml
  146. +4 −0 test/rails3_root/config.ru
  147. +46 −0 test/rails3_root/config/application.rb
  148. +6 −0 test/rails3_root/config/boot.rb
  149. +22 −0 test/rails3_root/config/database.yml
  150. +5 −0 test/rails3_root/config/environment.rb
  151. +19 −0 test/rails3_root/config/environments/development.rb
  152. +42 −0 test/rails3_root/config/environments/production.rb
  153. +32 −0 test/rails3_root/config/environments/test.rb
  154. +7 −0 test/rails3_root/config/initializers/backtrace_silencers.rb
  155. +10 −0 test/rails3_root/config/initializers/inflections.rb
  156. +5 −0 test/rails3_root/config/initializers/mime_types.rb
  157. +7 −0 test/rails3_root/config/initializers/secret_token.rb
  158. +8 −0 test/rails3_root/config/initializers/session_store.rb
  159. +5 −0 test/rails3_root/config/locales/en.yml
  160. +4 −0 test/rails3_root/config/routes.rb
  161. +19 −0 test/rails3_root/db/migrate/001_create_users.rb
  162. +13 −0 test/rails3_root/db/migrate/002_create_posts.rb
  163. +12 −0 test/rails3_root/db/migrate/003_create_taggings.rb
  164. +11 −0 test/rails3_root/db/migrate/004_create_tags.rb
  165. +12 −0 test/rails3_root/db/migrate/005_create_dogs.rb
  166. +14 −0 test/rails3_root/db/migrate/006_create_addresses.rb
  167. +11 −0 test/rails3_root/db/migrate/007_create_fleas.rb
  168. +12 −0 test/rails3_root/db/migrate/008_create_dogs_fleas.rb
  169. +17 −0 test/rails3_root/db/migrate/009_create_products.rb
  170. +14 −0 test/rails3_root/db/migrate/010_create_friendships.rb
  171. +12 −0 test/rails3_root/db/migrate/011_create_treats.rb
  172. +12 −0 test/rails3_root/db/migrate/20090506203502_create_profiles.rb
  173. +14 −0 test/rails3_root/db/migrate/20090506203536_create_registrations.rb
  174. +12 −0 test/rails3_root/db/migrate/20090513104502_create_cats.rb
  175. +7 −0 test/rails3_root/db/seeds.rb
  176. 0 test/rails3_root/lib/tasks/.gitkeep
  177. +26 −0 test/rails3_root/public/404.html
  178. +26 −0 test/rails3_root/public/422.html
  179. +26 −0 test/rails3_root/public/500.html
  180. 0 test/rails3_root/public/favicon.ico
  181. BIN test/rails3_root/public/images/rails.png
  182. +279 −0 test/rails3_root/public/index.html
  183. +2 −0 test/rails3_root/public/javascripts/application.js
  184. +965 −0 test/rails3_root/public/javascripts/controls.js
  185. +974 −0 test/rails3_root/public/javascripts/dragdrop.js
  186. +1,123 −0 test/rails3_root/public/javascripts/effects.js
  187. +4,874 −0 test/rails3_root/public/javascripts/prototype.js
  188. +118 −0 test/rails3_root/public/javascripts/rails.js
  189. +5 −0 test/rails3_root/public/robots.txt
  190. 0 test/rails3_root/public/stylesheets/.gitkeep
  191. +9 −0 test/rails3_root/script/rails
  192. +9 −0 test/rails3_root/test/performance/browsing_test.rb
  193. +13 −0 test/rails3_root/test/test_helper.rb
  194. 0 test/rails3_root/vendor/plugins/.gitkeep
  195. +6 −0 test/rails3_test_helper.rb
  196. +16 −8 test/test_helper.rb
  197. +1 −1 test/unit/address_test.rb
  198. +1 −1 test/unit/cat_test.rb
  199. +1 −1 test/unit/dog_test.rb
  200. +1 −1 test/unit/flea_test.rb
  201. +1 −1 test/unit/friendship_test.rb
  202. +1 −1 test/unit/post_test.rb
  203. +1 −1 test/unit/product_test.rb
  204. +1 −1 test/unit/tag_test.rb
  205. +1 −1 test/unit/tagging_test.rb
  206. +1 −1 test/unit/user_test.rb
View
@@ -1,7 +1,8 @@
-test/rails_root/log/*.log
+test/*/log/*.log
doc
coverage
.svn/
pkg
*.swp
+*.swo
tags
View
@@ -10,7 +10,7 @@ load 'tasks/shoulda.rake'
# Test::Unit::UI::VERBOSE
test_files_pattern = 'test/{unit,functional,other,matchers}/**/*_test.rb'
Rake::TestTask.new do |t|
- t.libs << 'lib'
+ t.libs << 'lib' << 'test'
t.pattern = test_files_pattern
t.verbose = false
end
@@ -35,8 +35,12 @@ task :sync_docs => 'rdoc' do
`rsync -ave ssh doc/ dev@dev.thoughtbot.com:/home/dev/www/dev.thoughtbot.com/shoulda`
end
-desc 'Default: run tests.'
-task :default => ['test']
+desc 'Default: run tests for all supported versions of Rails'
+task :default do
+ %w(2.3.8 3.0.0.beta3).each do |version|
+ system("RAILS_VERSION=#{version} rake -s test;")
+ end
+end
spec = Gem::Specification.new do |s|
s.name = "shoulda"
@@ -102,11 +102,7 @@ def equal_to_expected_value?
end
def assigned_value
- assigns[@variable]
- end
-
- def assigns
- @controller.response.template.assigns
+ @controller.instance_variable_get("@#{@variable}")
end
end
@@ -37,19 +37,36 @@ def description
private
def filters_params?
- @controller.respond_to?(:filter_parameters)
+ @controller.respond_to?(:filter_parameters) ||
+ request.respond_to?(:filtered_parameters)
end
def filters_key?
filtered_value == '[FILTERED]'
end
def filtered_value
+ if request.respond_to?(:filtered_parameters)
+ filtered_request_value
+ else
+ filtered_controller_value
+ end
+ end
+
+ def filtered_controller_value
filtered = @controller.send(:filter_parameters,
@key.to_s => @key.to_s)
filtered[@key.to_s]
end
+ def filtered_request_value
+ request.env['action_dispatch.request.parameters'] = { @key.to_s => 'value' }
+ request.filtered_parameters[@key.to_s]
+ end
+
+ def request
+ @request ||= ::ActionController::TestRequest.new
+ end
end
end
@@ -14,7 +14,7 @@ def render_template(template)
class RenderTemplateMatcher # :nodoc:
def initialize(template, context)
- @template = template
+ @template = template.to_s
@context = context
end
@@ -9,14 +9,21 @@ module Matchers
# it { should render_with_layout }
# it { should render_with_layout(:special) }
# it { should_not render_with_layout }
- def render_with_layout(layout = nil)
- RenderWithLayout.new(layout)
+ def render_with_layout(expected_layout = nil)
+ RenderWithLayout.new(expected_layout)
end
class RenderWithLayout # :nodoc:
- def initialize(layout)
- @layout = layout.to_s unless layout.nil?
+ def initialize(expected_layout)
+ @expected_layout = expected_layout.to_s unless expected_layout.nil?
+ end
+
+ # Used to provide access to layouts recorded by
+ # ActionController::TemplateAssertions in Rails 3
+ def in_context(context)
+ @context = context
+ self
end
def matches?(controller)
@@ -34,31 +41,41 @@ def negative_failure_message
def description
description = "render with "
- if @layout.nil?
+ if @expected_layout.nil?
description << "a layout"
else
- description << "the #{@layout.inspect} layout"
+ description << "the #{@expected_layout.inspect} layout"
end
description
end
private
def rendered_with_layout?
- !layout.blank?
+ !rendered_layouts.empty?
end
def rendered_with_expected_layout?
- return true if @layout.nil?
- layout == @layout
+ return true if @expected_layout.nil?
+ rendered_layouts.include?(@expected_layout)
end
- def layout
- layout = @controller.response.layout
- if layout.nil?
- nil
+ def rendered_layouts
+ if recorded_layouts
+ recorded_layouts.keys.compact.map { |layout| layout.sub(%r{^layouts/}, '') }
else
- layout.split('/').last
+ layout = @controller.response.layout
+ if layout.nil?
+ []
+ else
+ [layout.split('/').last]
+ end
+ end
+ end
+
+ def recorded_layouts
+ if @context
+ @context.instance_variable_get('@layouts')
end
end
@@ -68,7 +85,8 @@ def expectation
def result
if rendered_with_layout?
- "rendered with the #{layout.inspect} layout"
+ "rendered with " <<
+ rendered_layouts.map { |layout| layout.inspect }.join(", ")
else
"rendered without a layout"
end
@@ -55,7 +55,7 @@ def negative_failure_message
protected
def response_content_type
- @controller.response.content_type
+ @controller.response.content_type.to_s
end
def lookup_by_extension(extension)
@@ -64,7 +64,11 @@ def symbol_to_status_code(potential_symbol)
when :missing then 404
when :error then 500..599
when Symbol
- ::ActionController::StatusCodes::SYMBOL_TO_STATUS_CODE[potential_symbol]
+ if defined?(::Rack::Utils::SYMBOL_TO_STATUS_CODE)
+ ::Rack::Utils::SYMBOL_TO_STATUS_CODE[potential_symbol]
+ else
+ ::ActionController::Base::SYMBOL_TO_STATUS_CODE[potential_symbol]
+ end
else
potential_symbol
end
@@ -36,6 +36,7 @@ def initialize(method, path, context)
def to(params)
@params = params
+ stringify_params!
self
end
@@ -47,7 +48,6 @@ def in_context(context)
def matches?(controller)
@controller = controller
guess_controller!
- stringify_params!
route_recognized?
end
@@ -70,7 +70,11 @@ def assigned_value
end
def session
- @controller.response.session.data
+ if @controller.request.respond_to?(:session)
+ @controller.request.session.to_hash
+ else
+ @controller.response.session.data
+ end
end
def expectation
@@ -60,7 +60,7 @@ def regexp_value_matches?
end
def flash
- @controller.response.session['flash']
+ @controller.send(:flash)
end
def expectation
@@ -17,7 +17,12 @@ def pretty_error_messages(obj) # :nodoc:
# default_error_message(:too_long, :count => 60)
def default_error_message(key, values = {})
if Object.const_defined?(:I18n) # Rails >= 2.2
- I18n.translate("activerecord.errors.messages.#{key}", values)
+ result = I18n.translate("activerecord.errors.messages.#{key}", values)
+ if result =~ /^translation missing/
+ I18n.translate("errors.messages.#{key}", values)
+ else
+ result
+ end
else # Rails <= 2.1.x
::ActiveRecord::Errors.default_error_messages[key] % values[:count]
end
@@ -59,9 +59,17 @@ def description
def errors_match?
@instance.valid?
- @errors = @instance.errors.on(@attribute)
+ @errors = errors_for_attribute(@instance, @attribute)
@errors = [@errors] unless @errors.is_a?(Array)
- @expected_message ? (errors_match_regexp? || errors_match_string?) : (@errors != [nil])
+ @expected_message ? (errors_match_regexp? || errors_match_string?) : (@errors.compact.any?)
+ end
+
+ def errors_for_attribute(instance, attribute)
+ if instance.errors.respond_to?(:[])
+ instance.errors[attribute]
+ else
+ instance.errors.on(attribute)
+ end
end
def errors_match_regexp?
View
@@ -6,7 +6,3 @@
require 'shoulda/action_controller' if defined? ActionController::Base
require 'shoulda/action_mailer' if defined? ActionMailer::Base
-if defined?(RAILS_ROOT)
- # load in the 3rd party macros from vendorized plugins and gems
- Shoulda.autoload_macros RAILS_ROOT, File.join("vendor", "{plugins,gems}", "*")
-end
View
@@ -3,5 +3,6 @@
require 'shoulda/rspec'
else
require 'shoulda/rails'
+ Shoulda.autoload_macros RAILS_ROOT, File.join("vendor", "{plugins,gems}", "*")
end
end
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../test_helper'
+require 'test_helper'
require 'posts_controller'
# Re-raise errors caught by the controller.
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../test_helper'
+require 'test_helper'
require 'users_controller'
# Re-raise errors caught by the controller.
@@ -5,13 +5,24 @@ class HaveSentEmailTest < ActiveSupport::TestCase # :nodoc:
setup do
define_mailer :mailer, [:the_email] do
def the_email
- from "do-not-reply@example.com"
- recipients "myself@me.com"
- subject "This is spam"
- body :body => "Every email is spam."
+ if defined?(AbstractController::Rendering)
+ mail :from => "do-not-reply@example.com",
+ :to => "myself@me.com",
+ :subject => "This is spam",
+ :body => "Every email is spam."
+ else
+ from "do-not-reply@example.com"
+ recipients "myself@me.com"
+ subject "This is spam"
+ body "Every email is spam."
+ end
end
end
- @mail = Mailer.create_the_email
+ if defined?(AbstractController::Rendering)
+ @mail = Mailer.the_email
+ else
+ @mail = Mailer.create_the_email
+ end
end
should "accept based on the subject" do
@@ -1,4 +1,4 @@
-require File.join(File.dirname(__FILE__), '..', '..', 'test_helper')
+require 'test_helper'
class AllowMassAssignmentOfMatcherTest < ActiveSupport::TestCase # :nodoc:
@@ -1,4 +1,4 @@
-require File.join(File.dirname(__FILE__), '..', '..', 'test_helper')
+require 'test_helper'
class AllowValueMatcherTest < ActiveSupport::TestCase # :nodoc:
Oops, something went wrong.

0 comments on commit b1b6ac4

Please sign in to comment.