Class: FacebookApiMock

Inherits:
Object
  • Object
show all
Defined in:
lib/facebook_rails/test.rb

Overview

require ‘koala_rails.rb’

Instance Method Summary collapse

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, options = {})
  @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, options = {})
  @open_graph_data[:objects][object_id]
end