Class: Innate::Mock::Session
- Inherits:
-
Object
- Object
- Innate::Mock::Session
- Defined in:
- /home/manveru/github/ramaze/ramaze.net/tmp/git/innate/lib/innate/mock.rb
Instance Attribute Summary (collapse)
-
- (Object) cookie
Returns the value of attribute cookie.
Instance Method Summary (collapse)
-
- (Object) extract_cookie(method, path, hash = {})
-
- (Session) initialize
constructor
A new instance of Session.
Constructor Details
- (Session) initialize
Returns a new instance of Session
28 29 30 |
# File '/home/manveru/github/ramaze/ramaze.net/tmp/git/innate/lib/innate/mock.rb', line 28 def initialize @cookie = nil end |
Instance Attribute Details
- (Object) cookie
Returns the value of attribute cookie
26 27 28 |
# File '/home/manveru/github/ramaze/ramaze.net/tmp/git/innate/lib/innate/mock.rb', line 26 def @cookie end |
Instance Method Details
- (Object) extract_cookie(method, path, hash = {})
38 39 40 41 42 43 44 45 46 |
# File '/home/manveru/github/ramaze/ramaze.net/tmp/git/innate/lib/innate/mock.rb', line 38 def (method, path, hash = {}) hash['HTTP_COOKIE'] ||= @cookie if @cookie response = Mock::mock(method, path, hash) = response['Set-Cookie'] @cookie = if response end |