Class: FacebookApiMock
- Inherits:
-
Object
- Object
- FacebookApiMock
- Defined in:
- lib/facebook_rails/test.rb
Overview
require ‘koala_rails.rb’
Instance Method Summary collapse
- #get_connections(object_id, connection_name, options = {}) ⇒ Object
- #get_object(object_id, options = {}) ⇒ Object
-
#initialize(open_graph_data) ⇒ FacebookApiMock
constructor
A new instance of FacebookApiMock.
Constructor Details
#initialize(open_graph_data) ⇒ FacebookApiMock
Returns a new instance of FacebookApiMock.
8 9 10 |
# File 'lib/facebook_rails/test.rb', line 8 def initialize(open_graph_data) @open_graph_data = open_graph_data end |
Instance Method Details
#get_connections(object_id, connection_name, options = {}) ⇒ Object
16 17 18 |
# File 'lib/facebook_rails/test.rb', line 16 def get_connections(object_id, connection_name, = {}) @open_graph_data[:connections][object_id][connection_name] end |
#get_object(object_id, options = {}) ⇒ Object
12 13 14 |
# File 'lib/facebook_rails/test.rb', line 12 def get_object(object_id, = {}) @open_graph_data[:objects][object_id] end |