Sha256: af811d4e5898735ca40656b21c4461dc1eaeb8d1a8f952074c04d93b4a043e39

Contents?: true

Size: 347 Bytes

Versions: 8

Compression:

Stored size: 347 Bytes

Contents

RSpec::Matchers.define :be_accessible do |attribute|
  match do |response|
    response.class.accessible_attributes.include?(attribute.to_s)
  end
  description { "be accessible :#{attribute}" }
  failure_message_for_should { ":#{attribute} should be accessible" }
  failure_message_for_should_not { ":#{attribute} should not be accessible" }
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
fast_gettext-0.8.1 spec/support/be_accessible_matcher.rb
fast_gettext-0.8.0 spec/support/be_accessible_matcher.rb
fast_gettext-0.7.1 spec/support/be_accessible_matcher.rb
fast_gettext-0.7.0 spec/support/be_accessible_matcher.rb
fast_gettext-0.6.12 spec/support/be_accessible_matcher.rb
fast_gettext-0.6.11 spec/support/be_accessible_matcher.rb
fast_gettext-0.6.10 spec/support/be_accessible_matcher.rb
fast_gettext-0.6.9 spec/support/be_accessible_matcher.rb