Class: Sinatra::Application
- Inherits:
-
Object
- Object
- Sinatra::Application
- Defined in:
- lib/sorcery/test_helpers/internal/sinatra.rb
Class Attribute Summary collapse
-
.sorcery_vars ⇒ Object
Returns the value of attribute sorcery_vars.
Instance Method Summary collapse
-
#save_instance_vars ⇒ Object
NOTE: see before and after test filters in filters.rb.
Class Attribute Details
.sorcery_vars ⇒ Object
Returns the value of attribute sorcery_vars.
10 11 12 |
# File 'lib/sorcery/test_helpers/internal/sinatra.rb', line 10 def sorcery_vars @sorcery_vars end |
Instance Method Details
#save_instance_vars ⇒ Object
NOTE: see before and after test filters in filters.rb
16 17 18 19 20 |
# File 'lib/sorcery/test_helpers/internal/sinatra.rb', line 16 def save_instance_vars instance_variables.each do |var| self.class.sorcery_vars[:"#{var.to_s.delete("@")}"] = instance_variable_get(var) end end |