Class: Shoulda::Matchers::ActionController::SessionStore
- Inherits:
-
Object
- Object
- Shoulda::Matchers::ActionController::SessionStore
- Defined in:
- lib/shoulda/matchers/action_controller/session_store.rb
Instance Attribute Summary collapse
-
#controller ⇒ Object
Returns the value of attribute controller.
Instance Method Summary collapse
Instance Attribute Details
#controller ⇒ Object
Returns the value of attribute controller.
6 7 8 |
# File 'lib/shoulda/matchers/action_controller/session_store.rb', line 6 def controller @controller end |
Instance Method Details
#empty? ⇒ Boolean
22 23 24 |
# File 'lib/shoulda/matchers/action_controller/session_store.rb', line 22 def empty? session.empty? end |
#has_key?(key) ⇒ Boolean
12 13 14 |
# File 'lib/shoulda/matchers/action_controller/session_store.rb', line 12 def has_key?(key) session.key?(key) end |
#has_value?(expected_value) ⇒ Boolean
16 17 18 19 20 |
# File 'lib/shoulda/matchers/action_controller/session_store.rb', line 16 def has_value?(expected_value) session.values.any? do |actual_value| expected_value === actual_value end end |
#name ⇒ Object
8 9 10 |
# File 'lib/shoulda/matchers/action_controller/session_store.rb', line 8 def name 'session' end |