facebooker 1.0.18 → 1.0.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/{History.txt → CHANGELOG.rdoc} +0 -0
- data/{COPYING → COPYING.rdoc} +0 -0
- data/{README.txt → README.rdoc} +11 -4
- data/Rakefile +18 -15
- data/{TODO.txt → TODO.rdoc} +0 -0
- data/generators/facebook/templates/config/facebooker.yml +3 -0
- data/init.rb +12 -61
- data/lib/facebooker.rb +22 -15
- data/lib/facebooker/adapters/adapter_base.rb +3 -0
- data/lib/facebooker/logging.rb +1 -1
- data/lib/facebooker/model.rb +6 -4
- data/lib/facebooker/models/user.rb +39 -4
- data/lib/facebooker/parser.rb +14 -0
- data/lib/facebooker/rails/controller.rb +34 -10
- data/lib/facebooker/rails/extensions/action_controller.rb +48 -0
- data/lib/facebooker/rails/extensions/rack_setup.rb +2 -0
- data/lib/facebooker/rails/extensions/routing.rb +15 -0
- data/lib/facebooker/rails/facebook_url_helper.rb +3 -3
- data/lib/facebooker/rails/facebook_url_rewriting.rb +18 -5
- data/lib/facebooker/rails/helpers.rb +19 -2
- data/lib/facebooker/rails/helpers/fb_connect.rb +20 -10
- data/lib/facebooker/rails/publisher.rb +9 -5
- data/lib/facebooker/service.rb +1 -2
- data/lib/facebooker/session.rb +13 -1
- data/lib/facebooker/version.rb +1 -1
- data/lib/rack/facebook.rb +77 -0
- data/lib/tasks/tunnel.rake +3 -3
- data/test/facebooker/logging_test.rb +2 -2
- data/test/facebooker/models/user_test.rb +39 -3
- data/test/facebooker/rails/publisher_test.rb +19 -3
- data/test/facebooker/rails_integration_test.rb +52 -6
- data/test/rack/facebook_test.rb +62 -0
- data/test/rails_test_helper.rb +2 -0
- metadata +21 -27
- data/CHANGELOG.txt +0 -0
- data/Manifest.txt +0 -127
- data/README +0 -46
- data/lib/facebooker/models/user.rb.orig +0 -396
- data/lib/facebooker/models/user.rb.rej +0 -17
- data/lib/facebooker/session.rb.orig +0 -564
- data/lib/facebooker/session.rb.rej +0 -29
@@ -19,7 +19,7 @@ class Facebooker::LoggingTest < Test::Unit::TestCase
|
|
19
19
|
end
|
20
20
|
|
21
21
|
def test_does_not_crash_outside_rails
|
22
|
-
flexmock(Facebooker.logger, :logger).should_receive(:
|
22
|
+
flexmock(Facebooker.logger, :logger).should_receive(:info).once.with(String)
|
23
23
|
Facebooker::Logging.log_fb_api('sample.api.call',
|
24
24
|
{'param1' => true, 'param2' => 'value2'})
|
25
25
|
end
|
@@ -32,7 +32,7 @@ class Facebooker::LoggingTest < Test::Unit::TestCase
|
|
32
32
|
end
|
33
33
|
|
34
34
|
def test_plain_format
|
35
|
-
flexmock(Facebooker.logger, :logger).should_receive(:
|
35
|
+
flexmock(Facebooker.logger, :logger).should_receive(:info).once.with(
|
36
36
|
'sample.api.call (0) param1 = true')
|
37
37
|
Facebooker::Logging.log_fb_api('sample.api.call',
|
38
38
|
{'param1' => true})
|
@@ -76,15 +76,15 @@ class Facebooker::UserTest < Test::Unit::TestCase
|
|
76
76
|
end
|
77
77
|
|
78
78
|
def test_can_set_mobile_fbml
|
79
|
-
@user.expects(:set_profile_fbml).with(nil,"test",nil)
|
79
|
+
@user.expects(:set_profile_fbml).with(nil,"test",nil,nil)
|
80
80
|
@user.mobile_fbml="test"
|
81
81
|
end
|
82
82
|
def test_can_set_profile_action
|
83
|
-
@user.expects(:set_profile_fbml).with(nil,nil,"test")
|
83
|
+
@user.expects(:set_profile_fbml).with(nil,nil,"test",nil)
|
84
84
|
@user.profile_action="test"
|
85
85
|
end
|
86
86
|
def test_can_set_profile_fbml
|
87
|
-
@user.expects(:set_profile_fbml).with("test",nil,nil)
|
87
|
+
@user.expects(:set_profile_fbml).with("test",nil,nil,nil)
|
88
88
|
@user.profile_fbml="test"
|
89
89
|
end
|
90
90
|
|
@@ -185,6 +185,16 @@ class Facebooker::UserTest < Test::Unit::TestCase
|
|
185
185
|
assert_equal ["4228600737_c96da02bba97aedfd26136e980ae3761"],Facebooker::User.register([{:email=>"mary@example.com",:account_id=>1}])
|
186
186
|
end
|
187
187
|
|
188
|
+
def test_unregister_with_array
|
189
|
+
expect_http_posts_with_responses(unregister_response_xml)
|
190
|
+
assert_equal ["4228600737_c96da02bba97aedfd26136e980ae3761"],Facebooker::User.unregister(["4228600737_c96da02bba97aedfd26136e980ae3761"])
|
191
|
+
end
|
192
|
+
|
193
|
+
def test_unregister_emails_with_array
|
194
|
+
expect_http_posts_with_responses(unregister_response_xml)
|
195
|
+
assert_equal ["mary@example.com"],Facebooker::User.unregister_emails(["mary@example.com"])
|
196
|
+
end
|
197
|
+
|
188
198
|
def test_register_with_array_raises_if_not_all_success
|
189
199
|
expect_http_posts_with_responses(register_response_xml)
|
190
200
|
assert_equal ["4228600737_c96da02bba97aedfd26136e980ae3761"],Facebooker::User.register([{:email=>"mary@example.com",:account_id=>1},{:email=>"mike@example.com",:account_id=>2}])
|
@@ -193,6 +203,23 @@ class Facebooker::UserTest < Test::Unit::TestCase
|
|
193
203
|
assert_equal({:email=>"mike@example.com",:account_id=>2},e.failed_users.first)
|
194
204
|
end
|
195
205
|
|
206
|
+
def test_unregister_with_array_raises_if_not_all_success
|
207
|
+
expect_http_posts_with_responses(unregister_response_xml)
|
208
|
+
assert_equal ["4228600737_c96da02bba97aedfd26136e980ae3761"],Facebooker::User.unregister(["4228600737_c96da02bba97aedfd26136e980ae3761","3587916587_791214eb452bf4de30e957d65a0234d4"])
|
209
|
+
fail "Should have raised Facebooker::Session::UserUnRegistrationFailed"
|
210
|
+
rescue Facebooker::Session::UserUnRegistrationFailed => e
|
211
|
+
assert_equal("3587916587_791214eb452bf4de30e957d65a0234d4",e.failed_users.first)
|
212
|
+
end
|
213
|
+
|
214
|
+
def test_unregister_emails_with_array_raises_if_not_all_success
|
215
|
+
expect_http_posts_with_responses(unregister_response_xml)
|
216
|
+
assert_equal ["mary@example.com"],Facebooker::User.unregister_emails(["mary@example.com","mike@example.com"])
|
217
|
+
fail "Should have raised Facebooker::Session::UserUnRegistrationFailed"
|
218
|
+
rescue Facebooker::Session::UserUnRegistrationFailed => e
|
219
|
+
assert_equal("mike@example.com",e.failed_users.first)
|
220
|
+
end
|
221
|
+
|
222
|
+
|
196
223
|
def test_get_locale
|
197
224
|
@user = Facebooker::User.new(9507801, @session)
|
198
225
|
expect_http_posts_with_responses(example_users_get_info_xml)
|
@@ -283,6 +310,15 @@ class Facebooker::UserTest < Test::Unit::TestCase
|
|
283
310
|
XML
|
284
311
|
end
|
285
312
|
|
313
|
+
def unregister_response_xml
|
314
|
+
<<-XML
|
315
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
316
|
+
<connect_unregisterUsers_response xmlns="http://api.facebook.com/1.0/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://api.facebook.com/1.0/facebook.xsd" list="true">
|
317
|
+
<connect_unregisterUsers_response_elt>4228600737_c96da02bba97aedfd26136e980ae3761</connect_unregisterUsers_response_elt>
|
318
|
+
</connect_unregisterUsers_response>
|
319
|
+
XML
|
320
|
+
end
|
321
|
+
|
286
322
|
def has_app_permission_response_xml
|
287
323
|
<<-XML
|
288
324
|
<?xml version="1.0" encoding="UTF-8"?>
|
@@ -108,6 +108,13 @@ class TestPublisher < Facebooker::Rails::Publisher
|
|
108
108
|
from user
|
109
109
|
data :friend=>"Mike"
|
110
110
|
end
|
111
|
+
|
112
|
+
def user_action_with_template_id(user)
|
113
|
+
send_as :user_action
|
114
|
+
from user
|
115
|
+
data :friend=>"Mike"
|
116
|
+
template_id 4
|
117
|
+
end
|
111
118
|
def user_action_with_story_size(user)
|
112
119
|
send_as :user_action
|
113
120
|
from user
|
@@ -335,12 +342,21 @@ class Facebooker::Rails::Publisher::PublisherTest < Test::Unit::TestCase
|
|
335
342
|
ua = TestPublisher.create_user_action(@from_user)
|
336
343
|
assert_equal "user_action", ua.template_name
|
337
344
|
end
|
345
|
+
def test_create_user_action_with_template_id
|
346
|
+
@from_user = Facebooker::User.new
|
347
|
+
@session = Facebooker::Session.new("","")
|
348
|
+
@from_user.stubs(:session).returns(@session)
|
349
|
+
Facebooker::Rails::Publisher::FacebookTemplate.expects(:bundle_id_for_class_and_method).
|
350
|
+
with(TestPublisher,'user_action').never
|
351
|
+
ua = TestPublisher.create_user_action_with_template_id(@from_user)
|
352
|
+
assert_equal 4,ua.template_id
|
353
|
+
end
|
338
354
|
|
339
355
|
def test_publisher_user_action
|
340
356
|
@from_user = Facebooker::User.new
|
341
357
|
@session = Facebooker::Session.new("","")
|
342
358
|
@from_user.stubs(:session).returns(@session)
|
343
|
-
@session.expects(:publish_user_action).with(20309041537,{:friend=>"Mike"},nil,nil)
|
359
|
+
@session.expects(:publish_user_action).with(20309041537,{:friend=>"Mike"},nil,nil,nil)
|
344
360
|
|
345
361
|
Facebooker::Rails::Publisher::FacebookTemplate.expects(:bundle_id_for_class_and_method).
|
346
362
|
with(TestPublisher, 'user_action').
|
@@ -355,7 +371,7 @@ class Facebooker::Rails::Publisher::PublisherTest < Test::Unit::TestCase
|
|
355
371
|
@from_user = Facebooker::User.new
|
356
372
|
@session = Facebooker::Session.new("","")
|
357
373
|
@from_user.stubs(:session).returns(@session)
|
358
|
-
@session.expects(:publish_user_action).with(20309041537,{:friend=>"Mike"
|
374
|
+
@session.expects(:publish_user_action).with(20309041537,{:friend=>"Mike"},nil,nil,2)
|
359
375
|
|
360
376
|
Facebooker::Rails::Publisher::FacebookTemplate.expects(:bundle_id_for_class_and_method).
|
361
377
|
with(TestPublisher, 'user_action_with_story_size').
|
@@ -368,7 +384,7 @@ class Facebooker::Rails::Publisher::PublisherTest < Test::Unit::TestCase
|
|
368
384
|
@from_user = Facebooker::User.new
|
369
385
|
@session = Facebooker::Session.new("","")
|
370
386
|
@from_user.stubs(:session).returns(@session)
|
371
|
-
@session.expects(:publish_user_action).with(20309041537,{},nil,nil)
|
387
|
+
@session.expects(:publish_user_action).with(20309041537,{},nil,nil,nil)
|
372
388
|
|
373
389
|
Facebooker::Rails::Publisher::FacebookTemplate.stubs(:bundle_id_for_class_and_method).returns(20309041537)
|
374
390
|
TestPublisher.deliver_user_action_no_data(@from_user)
|
@@ -135,14 +135,23 @@ end
|
|
135
135
|
# you can't use asset_recognize, because it can't pass parameters in to the requests
|
136
136
|
class UrlRecognitionTests < Test::Unit::TestCase
|
137
137
|
def test_detects_in_canvas
|
138
|
-
|
138
|
+
if Rails.version < '2.3'
|
139
|
+
request = ActionController::TestRequest.new({"fb_sig_in_canvas"=>"1"}, {}, nil)
|
140
|
+
else
|
141
|
+
request = ActionController::TestRequest.new
|
142
|
+
request.query_parameters[:fb_sig_in_canvas] = "1"
|
143
|
+
end
|
139
144
|
request.path = "/"
|
140
145
|
ActionController::Routing::Routes.recognize(request)
|
141
146
|
assert_equal({"controller"=>"facebook","action"=>"index"},request.path_parameters)
|
142
147
|
end
|
143
148
|
|
144
149
|
def test_routes_when_not_in_canvas
|
145
|
-
|
150
|
+
if Rails.version < '2.3'
|
151
|
+
request = ActionController::TestRequest.new({}, {}, nil)
|
152
|
+
else
|
153
|
+
request = ActionController::TestRequest.new
|
154
|
+
end
|
146
155
|
request.path = "/"
|
147
156
|
ActionController::Routing::Routes.recognize(request)
|
148
157
|
assert_equal({"controller"=>"plain_old_rails","action"=>"index"},request.path_parameters)
|
@@ -428,6 +437,15 @@ class RailsIntegrationTest < Test::Unit::TestCase
|
|
428
437
|
assert_equal("<fb:redirect url=\"http://www.facebook.com/login.php?api_key=1234567&v=1.0\" />", @response.body)
|
429
438
|
end
|
430
439
|
|
440
|
+
def test_redirect_to_renders_javascript_redirect_if_request_is_for_a_facebook_iframe
|
441
|
+
get :index, facebook_params(:fb_sig_user => nil, :fb_sig_in_iframe => 1)
|
442
|
+
assert_response :success
|
443
|
+
assert_match "javascript", @response.body
|
444
|
+
assert_match "http-equiv", @response.body
|
445
|
+
assert_match "http://www.facebook.com/login.php?api_key=1234567&v=1.0".to_json, @response.body
|
446
|
+
assert_match "http://www.facebook.com/login.php?api_key=1234567&v=1.0", @response.body
|
447
|
+
end
|
448
|
+
|
431
449
|
def test_url_for_links_to_canvas_if_canvas_is_true_and_not_in_canvas
|
432
450
|
get :link_test, facebook_params(:fb_sig_in_canvas=>0,:canvas=>true)
|
433
451
|
assert_match /apps.facebook.com/,@response.body
|
@@ -581,6 +599,10 @@ class RailsHelperTest < Test::Unit::TestCase
|
|
581
599
|
assert_equal "<fb:profile-pic size=\"small\" uid=\"1234\"></fb:profile-pic>", @h.fb_profile_pic("1234", :size => :small)
|
582
600
|
end
|
583
601
|
|
602
|
+
def test_fb_profile_pic_with_width_and_height
|
603
|
+
assert_equal "<fb:profile-pic height=\"200\" uid=\"1234\" width=\"100\"></fb:profile-pic>", @h.fb_profile_pic("1234", :width => 100, :height => 200)
|
604
|
+
end
|
605
|
+
|
584
606
|
def test_fb_profile_pic_with_invalid_size
|
585
607
|
assert_raises(ArgumentError) {@h.fb_profile_pic("1234", :size => :mediumm)}
|
586
608
|
end
|
@@ -953,6 +975,20 @@ class RailsHelperTest < Test::Unit::TestCase
|
|
953
975
|
end
|
954
976
|
assert @h.output_buffer =~ /Body Content/
|
955
977
|
end
|
978
|
+
|
979
|
+
def test_init_fb_connect_no_options
|
980
|
+
assert ! @h.init_fb_connect.match(/Element.observe\(window,'load',/)
|
981
|
+
end
|
982
|
+
|
983
|
+
def test_init_fb_connect_with_options_js_jquery
|
984
|
+
assert ! @h.init_fb_connect(:js => :jquery).match(/\$\(document\).ready\(/)
|
985
|
+
end
|
986
|
+
|
987
|
+
def test_init_fb_connect_with_features_and_options_js_jquery
|
988
|
+
assert @h.init_fb_connect("XFBML", :js => :jquery).match(/XFBML.*/)
|
989
|
+
assert @h.init_fb_connect("XFBML", :js => :jquery).match(/\$\(document\).ready\(/)
|
990
|
+
end
|
991
|
+
|
956
992
|
|
957
993
|
def test_fb_login_and_redirect
|
958
994
|
assert_equal @h.fb_login_and_redirect("/path"),"<fb:login-button onlogin=\"window.location.href = "/path";\"></fb:login-button>"
|
@@ -961,6 +997,10 @@ class RailsHelperTest < Test::Unit::TestCase
|
|
961
997
|
def test_fb_logout_link
|
962
998
|
assert_equal @h.fb_logout_link("Logout","My URL"),"<a href=\"#\" onclick=\"FB.Connect.logoutAndRedirect("My URL");; return false;\">Logout</a>"
|
963
999
|
end
|
1000
|
+
def test_fb_user_action
|
1001
|
+
action = Facebooker::Rails::Publisher::UserAction.new
|
1002
|
+
assert_equal @h.fb_user_action(action,"message","prompt"),"FB.Connect.showFeedDialog(null, null, null, null, null, FB.RequireConnect.promptConnect, null, \"prompt\", \"message\");"
|
1003
|
+
end
|
964
1004
|
|
965
1005
|
|
966
1006
|
def test_fb_connect_javascript_tag
|
@@ -1105,30 +1145,28 @@ class RailsPrettyErrorsTest < Test::Unit::TestCase
|
|
1105
1145
|
end
|
1106
1146
|
|
1107
1147
|
def setup
|
1148
|
+
Facebooker.apply_configuration('api_key'=>"1234", 'secret_key'=>"34278",'canvas_page_name'=>'mike','pretty_errors'=>true)
|
1108
1149
|
@controller = ControllerWhichFails.new
|
1109
1150
|
@request = ActionController::TestRequest.new
|
1110
1151
|
@response = ActionController::TestResponse.new
|
1111
1152
|
end
|
1112
1153
|
|
1113
1154
|
def test_pretty_errors_disabled_success
|
1114
|
-
Facebooker.facebooker_config.stubs(:[]).with('pretty_errors').returns(false)
|
1115
1155
|
post :pass, facebook_params
|
1116
1156
|
assert_response 200
|
1117
1157
|
end
|
1118
1158
|
|
1119
1159
|
def test_pretty_errors_disabled_error
|
1120
|
-
Facebooker.
|
1160
|
+
Facebooker.apply_configuration('api_key'=>"1234", 'secret_key'=>"34278",'canvas_page_name'=>'mike','pretty_errors'=>false)
|
1121
1161
|
post :fail, facebook_params
|
1122
1162
|
assert_response :error
|
1123
1163
|
end
|
1124
1164
|
|
1125
1165
|
def test_pretty_errors_enabled_success
|
1126
|
-
Facebooker.facebooker_config.stubs(:[]).with('pretty_errors').returns(true)
|
1127
1166
|
post :pass, facebook_params
|
1128
1167
|
assert_response 200
|
1129
1168
|
end
|
1130
1169
|
def test_pretty_errors_enabled_error
|
1131
|
-
Facebooker.facebooker_config.stubs(:[]).with('pretty_errors').returns(true)
|
1132
1170
|
post :fail, facebook_params
|
1133
1171
|
assert_response 200
|
1134
1172
|
end
|
@@ -1288,6 +1326,9 @@ class RailsRequestFormatTest < Test::Unit::TestCase
|
|
1288
1326
|
end
|
1289
1327
|
|
1290
1328
|
def setup
|
1329
|
+
ENV['FACEBOOK_CANVAS_PATH'] ='facebook_app_name'
|
1330
|
+
ENV['FACEBOOK_API_KEY'] = '1234567'
|
1331
|
+
ENV['FACEBOOK_SECRET_KEY'] = '7654321'
|
1291
1332
|
@controller = FacebookController.new
|
1292
1333
|
@request = ActionController::TestRequest.new
|
1293
1334
|
@response = ActionController::TestResponse.new
|
@@ -1309,4 +1350,9 @@ class RailsRequestFormatTest < Test::Unit::TestCase
|
|
1309
1350
|
assert_equal 'fbjs', @response.body
|
1310
1351
|
end
|
1311
1352
|
|
1353
|
+
def test_responds_to_html_when_iframe
|
1354
|
+
get :index, facebook_params(:fb_sig_in_iframe => '1')
|
1355
|
+
assert_equal 'html', @response.body
|
1356
|
+
end
|
1357
|
+
|
1312
1358
|
end
|
@@ -0,0 +1,62 @@
|
|
1
|
+
require File.dirname(__FILE__) + '/../test_helper.rb'
|
2
|
+
require 'rack/facebook'
|
3
|
+
require 'rack/lint'
|
4
|
+
require 'rack/mock'
|
5
|
+
require 'ruby-debug'
|
6
|
+
|
7
|
+
class Rack::FacebookTest < Test::Unit::TestCase
|
8
|
+
|
9
|
+
def setup
|
10
|
+
@secret_key = 'secret'
|
11
|
+
@app = lambda do |env|
|
12
|
+
@env = env
|
13
|
+
Rack::Response.new().to_a
|
14
|
+
end
|
15
|
+
@facebook = Rack::Facebook.new(@app, @secret_key)
|
16
|
+
end
|
17
|
+
|
18
|
+
def params(p)
|
19
|
+
p.map{|*args| args.join('=') }.join('&')
|
20
|
+
end
|
21
|
+
|
22
|
+
def app
|
23
|
+
Rack::MockRequest.new(Rack::Lint.new(@facebook))
|
24
|
+
end
|
25
|
+
|
26
|
+
def test_without_fb_params
|
27
|
+
response = app.post("/")
|
28
|
+
assert_equal 200, response.status
|
29
|
+
end
|
30
|
+
|
31
|
+
def test_converts_request_method
|
32
|
+
response = app.post("/",
|
33
|
+
:input => params(:fb_sig_request_method => 'GET', :fb_sig => '4d2a700e90b0bcbe54b9e627d2cc1417'))
|
34
|
+
assert_equal 200, response.status
|
35
|
+
assert_equal 'GET', @env['REQUEST_METHOD']
|
36
|
+
end
|
37
|
+
|
38
|
+
def test_only_sets_request_method_if_provided
|
39
|
+
response = app.post("/", :input => params(:fb_sig_user => '1', :fb_sig => '313dd5caed3d0902d83225ff3ae9a950'))
|
40
|
+
assert_equal 200, response.status
|
41
|
+
assert_equal 'POST', @env['REQUEST_METHOD']
|
42
|
+
end
|
43
|
+
|
44
|
+
def test_renders_400_with_invalid_signature
|
45
|
+
response = app.post("/",
|
46
|
+
:input => params(:fb_sig => 'wrong', :fb_sig_user => 1))
|
47
|
+
assert_equal 400, response.status
|
48
|
+
end
|
49
|
+
|
50
|
+
def test_skips_with_false_condition
|
51
|
+
@facebook = Rack::Facebook.new(@app, @secret_key) { false }
|
52
|
+
response = app.post("/", :input => params(:fb_sig_user => 'ignored'))
|
53
|
+
assert_equal 200, response.status
|
54
|
+
end
|
55
|
+
|
56
|
+
def test_verifies_with_true_condition
|
57
|
+
@facebook = Rack::Facebook.new(@app, @secret_key) { true }
|
58
|
+
response = app.post("/", :input => params(:fb_sig_user => 'ignored'))
|
59
|
+
assert_equal 400, response.status
|
60
|
+
end
|
61
|
+
|
62
|
+
end
|
data/test/rails_test_helper.rb
CHANGED
@@ -3,6 +3,8 @@ require File.expand_path(File.dirname(__FILE__) + '/test_helper')
|
|
3
3
|
require 'action_controller'
|
4
4
|
require 'action_controller/test_process'
|
5
5
|
require 'active_record'
|
6
|
+
gem 'rails'
|
7
|
+
require 'initializer'
|
6
8
|
require File.dirname(__FILE__)+'/../init'
|
7
9
|
require 'facebooker/rails/controller'
|
8
10
|
require 'facebooker/rails/helpers/fb_connect'
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: facebooker
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.29
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Chad Fowler
|
@@ -13,7 +13,7 @@ autorequire:
|
|
13
13
|
bindir: bin
|
14
14
|
cert_chain: []
|
15
15
|
|
16
|
-
date: 2009-
|
16
|
+
date: 2009-04-21 00:00:00 -04:00
|
17
17
|
default_executable:
|
18
18
|
dependencies:
|
19
19
|
- !ruby/object:Gem::Dependency
|
@@ -34,32 +34,25 @@ dependencies:
|
|
34
34
|
requirements:
|
35
35
|
- - ">="
|
36
36
|
- !ruby/object:Gem::Version
|
37
|
-
version: 1.
|
37
|
+
version: 1.11.0
|
38
38
|
version:
|
39
|
-
description: "
|
39
|
+
description: "Facebooker is a Ruby wrapper over the Facebook[http://facebook.com] {REST API}[http://wiki.developers.facebook.com/index.php/API]. Its goals are: * Idiomatic Ruby * No dependencies outside of the Ruby standard library (This is true with Rails 2.1. Previous Rails versions require the JSON gem) * Concrete classes and methods modeling the Facebook data, so it's easy for a Rubyist to understand what's available * Well tested"
|
40
40
|
email: mmangino@elevatedrails.com
|
41
41
|
executables: []
|
42
42
|
|
43
43
|
extensions: []
|
44
44
|
|
45
45
|
extra_rdoc_files:
|
46
|
-
- CHANGELOG.
|
47
|
-
-
|
48
|
-
-
|
49
|
-
-
|
50
|
-
- TODO.txt
|
51
|
-
- test/fixtures/multipart_post_body_with_only_parameters.txt
|
52
|
-
- test/fixtures/multipart_post_body_with_single_file.txt
|
53
|
-
- test/fixtures/multipart_post_body_with_single_file_that_has_nil_key.txt
|
46
|
+
- CHANGELOG.rdoc
|
47
|
+
- COPYING.rdoc
|
48
|
+
- README.rdoc
|
49
|
+
- TODO.rdoc
|
54
50
|
files:
|
55
|
-
-
|
56
|
-
-
|
57
|
-
-
|
58
|
-
- Manifest.txt
|
59
|
-
- README
|
60
|
-
- README.txt
|
51
|
+
- COPYING.rdoc
|
52
|
+
- CHANGELOG.rdoc
|
53
|
+
- README.rdoc
|
61
54
|
- Rakefile
|
62
|
-
- TODO.
|
55
|
+
- TODO.rdoc
|
63
56
|
- generators/publisher/publisher_generator.rb
|
64
57
|
- generators/facebook/facebook_generator.rb
|
65
58
|
- generators/facebook/templates/config/facebooker.yml
|
@@ -103,9 +96,9 @@ files:
|
|
103
96
|
- lib/facebooker/data.rb
|
104
97
|
- lib/facebooker/feed.rb
|
105
98
|
- lib/facebooker/logging.rb
|
99
|
+
- lib/facebooker/mobile.rb
|
106
100
|
- lib/facebooker/mock/service.rb
|
107
101
|
- lib/facebooker/mock/session.rb
|
108
|
-
- lib/facebooker/mobile.rb
|
109
102
|
- lib/facebooker/model.rb
|
110
103
|
- lib/facebooker/models/affiliation.rb
|
111
104
|
- lib/facebooker/models/album.rb
|
@@ -124,14 +117,15 @@ files:
|
|
124
117
|
- lib/facebooker/models/photo.rb
|
125
118
|
- lib/facebooker/models/tag.rb
|
126
119
|
- lib/facebooker/models/user.rb
|
127
|
-
- lib/facebooker/models/user.rb.orig
|
128
|
-
- lib/facebooker/models/user.rb.rej
|
129
120
|
- lib/facebooker/models/video.rb
|
130
121
|
- lib/facebooker/models/work_info.rb
|
131
122
|
- lib/facebooker/parser.rb
|
132
123
|
- lib/facebooker/rails/controller.rb
|
133
124
|
- lib/facebooker/rails/cucumber/world.rb
|
134
125
|
- lib/facebooker/rails/cucumber.rb
|
126
|
+
- lib/facebooker/rails/extensions/action_controller.rb
|
127
|
+
- lib/facebooker/rails/extensions/rack_setup.rb
|
128
|
+
- lib/facebooker/rails/extensions/routing.rb
|
135
129
|
- lib/facebooker/rails/facebook_form_builder.rb
|
136
130
|
- lib/facebooker/rails/facebook_pretty_errors.rb
|
137
131
|
- lib/facebooker/rails/facebook_request_fix.rb
|
@@ -149,11 +143,10 @@ files:
|
|
149
143
|
- lib/facebooker/server_cache.rb
|
150
144
|
- lib/facebooker/service.rb
|
151
145
|
- lib/facebooker/session.rb
|
152
|
-
- lib/facebooker/session.rb.orig
|
153
|
-
- lib/facebooker/session.rb.rej
|
154
146
|
- lib/facebooker/version.rb
|
155
147
|
- lib/facebooker.rb
|
156
148
|
- lib/net/http_multipart_post.rb
|
149
|
+
- lib/rack/facebook.rb
|
157
150
|
- lib/tasks/facebooker.rake
|
158
151
|
- lib/tasks/tunnel.rake
|
159
152
|
- rails/init.rb
|
@@ -180,11 +173,11 @@ files:
|
|
180
173
|
- test/test_helper.rb
|
181
174
|
- test/facebooker/mobile_test.rb
|
182
175
|
has_rdoc: true
|
183
|
-
homepage:
|
176
|
+
homepage: http://facebooker.rubyforge.org
|
184
177
|
post_install_message:
|
185
178
|
rdoc_options:
|
186
179
|
- --main
|
187
|
-
- README.
|
180
|
+
- README.rdoc
|
188
181
|
require_paths:
|
189
182
|
- lib
|
190
183
|
required_ruby_version: !ruby/object:Gem::Requirement
|
@@ -205,7 +198,7 @@ rubyforge_project: facebooker
|
|
205
198
|
rubygems_version: 1.3.1
|
206
199
|
signing_key:
|
207
200
|
specification_version: 2
|
208
|
-
summary:
|
201
|
+
summary: Facebooker is a Ruby wrapper over the Facebook[http://facebook.com] {REST API}[http://wiki.developers.facebook.com/index.php/API]
|
209
202
|
test_files:
|
210
203
|
- test/facebooker_test.rb
|
211
204
|
- test/facebooker/adapters_test.rb
|
@@ -222,3 +215,4 @@ test_files:
|
|
222
215
|
- test/facebooker/models/user_test.rb
|
223
216
|
- test/facebooker/rails/publisher_test.rb
|
224
217
|
- test/net/http_multipart_post_test.rb
|
218
|
+
- test/rack/facebook_test.rb
|