Module: Ww::Double::Spy
- Defined in:
- lib/ww/double/spy.rb,
lib/ww/double/spy/request.rb
Defined Under Namespace
Modules: InstanceMethods
Classes: Request
Class Method Summary
collapse
Instance Method Summary
collapse
Class Method Details
.decode_json(json_string) ⇒ Object
8
9
10
|
# File 'lib/ww/double/spy/request.rb', line 8
def decode_json(json_string)
ActiveSupport::JSON.decode(json_string)
end
|
Instance Method Details
#requests ⇒ Object
16
17
18
|
# File 'lib/ww/double/spy.rb', line 16
def requests
@requests ||= Store.new
end
|
#spy_them_all! ⇒ Object
12
13
14
|
# File 'lib/ww/double/spy.rb', line 12
def spy_them_all!
before { spy! }
end
|
#store(req) ⇒ Object
20
21
22
|
# File 'lib/ww/double/spy.rb', line 20
def store(req)
requests.store(Request.new(req))
end
|