Module: Spreewald::Compatibility
- Defined in:
- lib/spreewald_support/compatibility.rb
Class Method Summary collapse
- .spreewald_failure_message(context, &block) ⇒ Object
- .spreewald_failure_message_negated(context, &block) ⇒ Object
Class Method Details
.spreewald_failure_message(context, &block) ⇒ Object
4 5 6 7 8 9 10 |
# File 'lib/spreewald_support/compatibility.rb', line 4 def self.(context, &block) if context.respond_to?(:failure_message) context.(&block) else context.(&block) end end |
.spreewald_failure_message_negated(context, &block) ⇒ Object
12 13 14 15 16 17 18 |
# File 'lib/spreewald_support/compatibility.rb', line 12 def self.(context, &block) if context.respond_to?(:failure_message_when_negated) context.(&block) else context.(&block) end end |