rest-more 2.0.0 → 2.0.2

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/.gitignore CHANGED
@@ -1,2 +1,3 @@
1
1
  pkg
2
2
  *.rbc
3
+ Gemfile.lock
data/CHANGES.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # CHANGES
2
2
 
3
+ ## rest-more 2.0.2 -- 2013-02-07
4
+
5
+ * Updated Facebook OAuth URL from https://graph.facebook.com/oauth/authorize
6
+ to https://www.facebook.com/dialog/oauth
7
+
3
8
  ## rest-more 2.0.0 -- 2012-10-31
4
9
 
5
10
  * Adopted to rest-core 2.0.0, a whole new generation.
data/Gemfile CHANGED
@@ -31,4 +31,4 @@ platforms(:jruby) do
31
31
  gem 'jruby-openssl'
32
32
  end
33
33
 
34
- gem 'rails', '3.2.8' if ENV['RESTMORE'] == 'rails3'
34
+ gem 'rails', '3.2.11' if ENV['RESTMORE'] == 'rails3'
data/README.md CHANGED
@@ -168,6 +168,7 @@ Which is using `RestCore::Universal` for accessing arbitrary websites.
168
168
  ## CONTRIBUTORS:
169
169
 
170
170
  * ayaya (@ayamomiji)
171
+ * Fumin (@fumin)
171
172
  * Lin Jen-Shin (@godfat)
172
173
  * Yun-Yan Chi (@jaiyalas)
173
174
 
data/Rakefile CHANGED
@@ -36,7 +36,7 @@ module Gemgem
36
36
  def test_rails *rails
37
37
  rails.each{ |framework|
38
38
  opts = Rake.application.options
39
- args = (opts.singleton_methods - [:rakelib, 'rakelib']).map{ |arg|
39
+ args = (opts.singleton_methods - [:rakelib, :trace_output]).map{ |arg|
40
40
  if arg.to_s !~ /=$/ && opts.send(arg)
41
41
  "--#{arg}"
42
42
  else
@@ -1,7 +1,7 @@
1
1
 
2
2
  source 'http://rubygems.org'
3
3
 
4
- gem 'rails', '3.2.8'
4
+ gem 'rails', '3.2.11'
5
5
 
6
6
  gem 'rest-client' # for rest-core
7
7
  gem 'rest-core', :path => '../../rest-core'
@@ -47,7 +47,7 @@ class ApplicationControllerTest < ActionController::TestCase
47
47
  assert_response :redirect
48
48
 
49
49
  url = normalize_url(
50
- 'https://graph.facebook.com/oauth/authorize?client_id=123&' \
50
+ 'https://www.facebook.com/dialog/oauth?client_id=123&' \
51
51
  'scope=&redirect_uri=http%3A%2F%2Ftest.host%2F')
52
52
 
53
53
  assert_url(url)
@@ -58,7 +58,7 @@ class ApplicationControllerTest < ActionController::TestCase
58
58
  assert_response :success
59
59
 
60
60
  url = normalize_url(
61
- 'https://graph.facebook.com/oauth/authorize?client_id=123&' \
61
+ 'https://www.facebook.com/dialog/oauth?client_id=123&' \
62
62
  'scope=publish_stream&' \
63
63
  'redirect_uri=http%3A%2F%2Fapps.facebook.com%2Fcan%2Fcanvas')
64
64
 
@@ -70,7 +70,7 @@ class ApplicationControllerTest < ActionController::TestCase
70
70
  assert_response :success
71
71
 
72
72
  url = normalize_url(
73
- 'https://graph.facebook.com/oauth/authorize?client_id=123&' \
73
+ 'https://www.facebook.com/dialog/oauth?client_id=123&' \
74
74
  'scope=email&' \
75
75
  'redirect_uri=http%3A%2F%2Fapps.facebook.com%2FToT%2Fdiff_canvas')
76
76
 
@@ -82,7 +82,7 @@ class ApplicationControllerTest < ActionController::TestCase
82
82
  assert_response :success
83
83
 
84
84
  url = normalize_url(
85
- 'https://graph.facebook.com/oauth/authorize?client_id=123&' \
85
+ 'https://www.facebook.com/dialog/oauth?client_id=123&' \
86
86
  'scope=&' \
87
87
  'redirect_uri=http%3A%2F%2Fapps.facebook.com%2Fzzz%2Fiframe_canvas')
88
88
 
@@ -94,7 +94,7 @@ class ApplicationControllerTest < ActionController::TestCase
94
94
  assert_response :redirect
95
95
 
96
96
  url = normalize_url(
97
- 'https://graph.facebook.com/oauth/authorize?client_id=123&' \
97
+ 'https://www.facebook.com/dialog/oauth?client_id=123&' \
98
98
  'scope=bogus&' \
99
99
  'redirect_uri=http%3A%2F%2Ftest.host%2Foptions')
100
100
 
@@ -10,7 +10,7 @@ module RestCore
10
10
 
11
11
  use DefaultSite , 'https://graph.facebook.com/'
12
12
  use DefaultHeaders, {'Accept' => 'application/json',
13
- 'Accept-Language' => 'en-us'}
13
+ 'Accept-Language' => 'en-us'}
14
14
  use Oauth2Query , nil
15
15
 
16
16
  use CommonLogger , nil
@@ -211,8 +211,9 @@ module RestCore::Facebook::Client
211
211
  # oauth related
212
212
 
213
213
  def authorize_url opts={}
214
- url('oauth/authorize',
215
- {:client_id => app_id, :access_token => nil}.merge(opts))
214
+ url('dialog/oauth',
215
+ {:client_id => app_id, :access_token => nil}.merge(opts),
216
+ :site => 'https://www.facebook.com/')
216
217
  end
217
218
 
218
219
  def authorize! opts={}
@@ -1,4 +1,4 @@
1
1
 
2
2
  module RestMore
3
- VERSION = '2.0.0'
3
+ VERSION = '2.0.2'
4
4
  end
data/rest-more.gemspec CHANGED
@@ -2,13 +2,13 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = "rest-more"
5
- s.version = "2.0.0"
5
+ s.version = "2.0.2"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = [
9
9
  "Cardinal Blue",
10
10
  "Lin Jen-Shin (godfat)"]
11
- s.date = "2012-10-31"
11
+ s.date = "2013-02-07"
12
12
  s.description = "Various REST clients such as Facebook and Twitter built with [rest-core][]\n\n[rest-core]: https://github.com/cardinalblue/rest-core"
13
13
  s.email = ["dev (XD) cardinalblue.com"]
14
14
  s.executables = ["rib-rest-core"]
@@ -82,7 +82,7 @@ Gem::Specification.new do |s|
82
82
  "test/twitter/test_api.rb"]
83
83
  s.homepage = "https://github.com/cardinalblue/rest-more"
84
84
  s.require_paths = ["lib"]
85
- s.rubygems_version = "1.8.24"
85
+ s.rubygems_version = "1.8.23"
86
86
  s.summary = "Various REST clients such as Facebook and Twitter built with [rest-core][]"
87
87
  s.test_files = [
88
88
  "test/dropbox/test_api.rb",
@@ -13,7 +13,7 @@ describe RC::Facebook do
13
13
 
14
14
  should 'return correct oauth url' do
15
15
  TestHelper.normalize_url(@rg.authorize_url(:redirect_uri => @uri)).
16
- should.eq 'https://graph.facebook.com/oauth/authorize?' \
16
+ should.eq 'https://www.facebook.com/dialog/oauth?' \
17
17
  'client_id=29&redirect_uri=http%3A%2F%2Fzzz.tw'
18
18
  end
19
19
 
@@ -34,7 +34,7 @@ describe RC::Facebook do
34
34
 
35
35
  should 'not append access_token in authorize_url even presented' do
36
36
  RC::Facebook.new(:access_token => 'do not use me').authorize_url.
37
- should.eq 'https://graph.facebook.com/oauth/authorize'
37
+ should.eq 'https://www.facebook.com/dialog/oauth'
38
38
  end
39
39
 
40
40
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rest-more
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 2.0.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2012-10-31 00:00:00.000000000 Z
13
+ date: 2013-02-07 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: rest-core
@@ -126,7 +126,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
126
126
  version: '0'
127
127
  requirements: []
128
128
  rubyforge_project:
129
- rubygems_version: 1.8.24
129
+ rubygems_version: 1.8.23
130
130
  signing_key:
131
131
  specification_version: 3
132
132
  summary: Various REST clients such as Facebook and Twitter built with [rest-core][]
@@ -145,4 +145,3 @@ test_files:
145
145
  - test/facebook/test_serialize.rb
146
146
  - test/facebook/test_timeout.rb
147
147
  - test/twitter/test_api.rb
148
- has_rdoc: