oauth 0.4.7 → 0.5.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of oauth might be problematic. Click here for more details.

Files changed (65) hide show
  1. checksums.yaml +7 -0
  2. data/README.rdoc +8 -8
  3. data/lib/oauth.rb +1 -3
  4. data/lib/oauth/cli.rb +3 -3
  5. data/lib/oauth/client/helper.rb +4 -0
  6. data/lib/oauth/client/net_http.rb +9 -7
  7. data/lib/oauth/consumer.rb +9 -5
  8. data/lib/oauth/helper.rb +3 -3
  9. data/lib/oauth/request_proxy/action_controller_request.rb +26 -2
  10. data/lib/oauth/request_proxy/base.rb +1 -1
  11. data/lib/oauth/request_proxy/net_http.rb +1 -1
  12. data/lib/oauth/request_proxy/rest_client_request.rb +62 -0
  13. data/lib/oauth/request_proxy/typhoeus_request.rb +4 -3
  14. data/lib/oauth/signature/base.rb +9 -23
  15. data/lib/oauth/signature/hmac/sha1.rb +12 -4
  16. data/lib/oauth/signature/plaintext.rb +6 -0
  17. data/lib/oauth/signature/rsa/sha1.rb +7 -3
  18. data/lib/oauth/tokens/access_token.rb +12 -0
  19. data/lib/oauth/tokens/request_token.rb +5 -0
  20. data/lib/oauth/tokens/token.rb +1 -1
  21. data/lib/oauth/version.rb +3 -0
  22. data/test/cases/oauth_case.rb +2 -2
  23. data/test/integration/consumer_test.rb +13 -13
  24. data/test/test_access_token.rb +2 -2
  25. data/test/test_action_controller_request_proxy.rb +29 -5
  26. data/test/test_consumer.rb +9 -3
  27. data/test/test_curb_request_proxy.rb +1 -1
  28. data/test/test_em_http_client.rb +1 -1
  29. data/test/test_em_http_request_proxy.rb +1 -1
  30. data/test/test_helper.rb +8 -3
  31. data/test/test_hmac_sha1.rb +1 -1
  32. data/test/test_net_http_client.rb +7 -1
  33. data/test/test_net_http_request_proxy.rb +1 -1
  34. data/test/test_oauth_helper.rb +5 -5
  35. data/test/test_rack_request_proxy.rb +1 -1
  36. data/test/test_request_token.rb +9 -4
  37. data/test/test_rest_client_request_proxy.rb +81 -0
  38. data/test/test_rsa_sha1.rb +1 -1
  39. data/test/test_server.rb +7 -6
  40. data/test/test_signature.rb +6 -13
  41. data/test/test_signature_base.rb +6 -6
  42. data/test/test_signature_hmac_sha1.rb +40 -0
  43. data/test/test_signature_plain_text.rb +1 -1
  44. data/test/test_token.rb +1 -1
  45. data/test/test_typhoeus_request_proxy.rb +24 -3
  46. metadata +126 -74
  47. data/.gemtest +0 -0
  48. data/Gemfile +0 -16
  49. data/Gemfile.lock +0 -47
  50. data/HISTORY +0 -173
  51. data/Rakefile +0 -37
  52. data/examples/yql.rb +0 -44
  53. data/lib/digest/hmac.rb +0 -104
  54. data/lib/oauth/signature/hmac/base.rb +0 -15
  55. data/lib/oauth/signature/hmac/md5.rb +0 -8
  56. data/lib/oauth/signature/hmac/rmd160.rb +0 -8
  57. data/lib/oauth/signature/hmac/sha2.rb +0 -8
  58. data/lib/oauth/signature/md5.rb +0 -13
  59. data/lib/oauth/signature/sha1.rb +0 -13
  60. data/oauth.gemspec +0 -148
  61. data/tasks/deployment.rake +0 -34
  62. data/tasks/environment.rake +0 -7
  63. data/tasks/website.rake +0 -17
  64. data/test/keys/rsa.cert +0 -11
  65. data/test/keys/rsa.pem +0 -16
@@ -16,6 +16,12 @@ module OAuth::Signature
16
16
  secret
17
17
  end
18
18
 
19
+ def body_hash
20
+ nil
21
+ end
22
+
23
+ private
24
+
19
25
  def secret
20
26
  super
21
27
  end
@@ -1,10 +1,8 @@
1
1
  require 'oauth/signature/base'
2
- require 'openssl'
3
2
 
4
3
  module OAuth::Signature::RSA
5
4
  class SHA1 < OAuth::Signature::Base
6
5
  implements 'rsa-sha1'
7
- hash_class ::Digest::SHA1
8
6
 
9
7
  def ==(cmp_signature)
10
8
  public_key.verify(OpenSSL::Digest::SHA1.new, Base64.decode64(cmp_signature.is_a?(Array) ? cmp_signature.first : cmp_signature), signature_base_string)
@@ -20,7 +18,11 @@ module OAuth::Signature::RSA
20
18
  end
21
19
  end
22
20
 
23
- private
21
+ def body_hash
22
+ Base64.encode64(OpenSSL::Digest::SHA1.digest(request.body || '')).chomp.gsub(/\n/,'')
23
+ end
24
+
25
+ private
24
26
 
25
27
  def decode_public_key
26
28
  case consumer_secret
@@ -35,6 +37,8 @@ module OAuth::Signature::RSA
35
37
  private_key = OpenSSL::PKey::RSA.new(
36
38
  if options[:private_key_file]
37
39
  IO.read(options[:private_key_file])
40
+ elsif options[:private_key]
41
+ options[:private_key]
38
42
  else
39
43
  consumer_secret
40
44
  end
@@ -59,6 +59,18 @@ module OAuth
59
59
  request(:put, path, body, headers)
60
60
  end
61
61
 
62
+ # Make a regular PATCH request using AccessToken
63
+ #
64
+ # @response = @token.patch('/people/123')
65
+ # @response = @token.patch('/people/123', { :name => 'Bob', :email => 'bob@mailinator.com' })
66
+ # @response = @token.patch('/people/123', { :name => 'Bob', :email => 'bob@mailinator.com' }, { 'Accept' => 'application/xml' })
67
+ # @response = @token.patch('/people/123', nil, { 'Accept' => 'application/xml' })
68
+ # @response = @token.patch('/people/123', @person.to_xml, { 'Accept' => 'application/xml', 'Content-Type' => 'application/xml' })
69
+ #
70
+ def patch(path, body = '', headers = {})
71
+ request(:patch, path, body, headers)
72
+ end
73
+
62
74
  # Make a regular DELETE request using AccessToken
63
75
  #
64
76
  # @response = @token.delete('/people/123')
@@ -5,6 +5,8 @@ module OAuth
5
5
 
6
6
  # Generate an authorization URL for user authorization
7
7
  def authorize_url(params = nil)
8
+ return nil if self.token.nil?
9
+
8
10
  params = (params || {}).merge(:oauth_token => self.token)
9
11
  build_authorize_url(consumer.authorize_url, params)
10
12
  end
@@ -24,6 +26,9 @@ module OAuth
24
26
  # construct an authorization url
25
27
  def build_authorize_url(base_url, params)
26
28
  uri = URI.parse(base_url.to_s)
29
+ if(!uri.query.blank? && !params.empty?)
30
+ uri.query += "&"
31
+ end
27
32
  # TODO doesn't handle array values correctly
28
33
  uri.query = params.map { |k,v| [k, CGI.escape(v)] * "=" } * "&"
29
34
  uri.to_s
@@ -11,7 +11,7 @@ module OAuth
11
11
  end
12
12
 
13
13
  def to_query
14
- "oauth_token=#{escape(token)}&oauth_secret=#{escape(secret)}"
14
+ "oauth_token=#{escape(token)}&oauth_token_secret=#{escape(secret)}"
15
15
  end
16
16
  end
17
17
  end
@@ -0,0 +1,3 @@
1
+ module OAuth
2
+ VERSION = "0.5.0"
3
+ end
@@ -1,9 +1,9 @@
1
- require 'test/unit'
1
+ require 'minitest/autorun'
2
2
  require 'oauth/signature'
3
3
  require 'oauth/request_proxy/mock_request'
4
4
 
5
5
 
6
- class OAuthCase < Test::Unit::TestCase
6
+ class OAuthCase < Minitest::Test
7
7
  # avoid whining about a lack of tests
8
8
  def run(*args)
9
9
  return if @method_name.to_s == "default_test"
@@ -1,7 +1,7 @@
1
1
  require File.expand_path('../../test_helper', __FILE__)
2
2
 
3
3
  module Integration
4
- class ConsumerTest < Test::Unit::TestCase
4
+ class ConsumerTest < Minitest::Test
5
5
  def setup
6
6
  @consumer=OAuth::Consumer.new(
7
7
  'consumer_key_86cad9', '5888bf0345e5d237',
@@ -39,7 +39,7 @@ module Integration
39
39
  token = OAuth::ConsumerToken.new(consumer, 'token_411a7f', '3196ffd991c8ebdb')
40
40
  token.sign!(request, {:nonce => @nonce, :timestamp => @timestamp})
41
41
 
42
- assert_no_match( /oauth_signature_method="HMAC-SHA1"/, request['authorization'])
42
+ refute_match( /oauth_signature_method="HMAC-SHA1"/, request['authorization'])
43
43
  assert_match( /oauth_signature_method="PLAINTEXT"/, request['authorization'])
44
44
  end
45
45
 
@@ -52,7 +52,7 @@ module Integration
52
52
  request = Net::HTTP::Get.new('/')
53
53
  signature_base_string = consumer.signature_base_string(request)
54
54
 
55
- assert_no_match( /HMAC-SHA1/, signature_base_string)
55
+ refute_match( /HMAC-SHA1/, signature_base_string)
56
56
  assert_equal( "#{consumer.secret}&", signature_base_string)
57
57
  end
58
58
 
@@ -162,23 +162,23 @@ module Integration
162
162
  assert !@consumer.authorize_url?, "Should not use fully qualified url"
163
163
 
164
164
  @request_token=@consumer.get_request_token
165
- assert_not_nil @request_token
165
+ assert @request_token
166
166
  assert_equal "requestkey",@request_token.token
167
167
  assert_equal "requestsecret",@request_token.secret
168
168
  assert_equal "http://term.ie/oauth/example/authorize.php?oauth_token=requestkey",@request_token.authorize_url
169
169
 
170
170
  @access_token=@request_token.get_access_token
171
- assert_not_nil @access_token
171
+ assert @access_token
172
172
  assert_equal "accesskey",@access_token.token
173
173
  assert_equal "accesssecret",@access_token.secret
174
174
 
175
175
  @response=@access_token.get("/oauth/example/echo_api.php?ok=hello&test=this")
176
- assert_not_nil @response
176
+ assert @response
177
177
  assert_equal "200",@response.code
178
178
  assert_equal( "ok=hello&test=this",@response.body)
179
179
 
180
180
  @response=@access_token.post("/oauth/example/echo_api.php",{'ok'=>'hello','test'=>'this'})
181
- assert_not_nil @response
181
+ assert @response
182
182
  assert_equal "200",@response.code
183
183
  assert_equal( "ok=hello&test=this",@response.body)
184
184
  end
@@ -203,23 +203,23 @@ module Integration
203
203
  assert @consumer.authorize_url?, "Should use fully qualified url"
204
204
 
205
205
  @request_token=@consumer.get_request_token
206
- assert_not_nil @request_token
206
+ assert @request_token
207
207
  assert_equal "requestkey",@request_token.token
208
208
  assert_equal "requestsecret",@request_token.secret
209
209
  assert_equal "http://term.ie/oauth/example/authorize.php?oauth_token=requestkey",@request_token.authorize_url
210
210
 
211
211
  @access_token=@request_token.get_access_token
212
- assert_not_nil @access_token
212
+ assert @access_token
213
213
  assert_equal "accesskey",@access_token.token
214
214
  assert_equal "accesssecret",@access_token.secret
215
215
 
216
216
  @response=@access_token.get("/oauth/example/echo_api.php?ok=hello&test=this")
217
- assert_not_nil @response
217
+ assert @response
218
218
  assert_equal "200",@response.code
219
219
  assert_equal( "ok=hello&test=this",@response.body)
220
220
 
221
221
  @response=@access_token.post("/oauth/example/echo_api.php",{'ok'=>'hello','test'=>'this'})
222
- assert_not_nil @response
222
+ assert @response
223
223
  assert_equal "200",@response.code
224
224
  assert_equal( "ok=hello&test=this",@response.body)
225
225
  end
@@ -283,13 +283,13 @@ module Integration
283
283
  request_body_stream = StringIO.new( request_body_string )
284
284
 
285
285
  @response=@access_token.post("/oauth/example/echo_api.php",request_body_stream)
286
- assert_not_nil @response
286
+ assert @response
287
287
  assert_equal "200",@response.code
288
288
 
289
289
  request_body_file = File.open(__FILE__)
290
290
 
291
291
  @response=@access_token.post("/oauth/example/echo_api.php",request_body_file)
292
- assert_not_nil @response
292
+ assert @response
293
293
  assert_equal "200",@response.code
294
294
 
295
295
  # unfortunately I don't know of a way to test that the body data was received correctly since the test server at http://term.ie
@@ -1,6 +1,6 @@
1
1
  require File.expand_path('../test_helper', __FILE__)
2
2
 
3
- class TestAccessToken < Test::Unit::TestCase
3
+ class TestAccessToken < Minitest::Test
4
4
  def setup
5
5
  @fake_response = {
6
6
  :user_id => 5734758743895,
@@ -20,7 +20,7 @@ class TestAccessToken < Test::Unit::TestCase
20
20
  end
21
21
 
22
22
  def test_access_token_makes_non_oauth_response_params_available
23
- assert_not_nil @access_token.params[:user_id]
23
+ assert @access_token.params[:user_id]
24
24
  assert_equal 5734758743895, @access_token.params[:user_id]
25
25
  end
26
26
  end
@@ -1,20 +1,20 @@
1
- gem 'actionpack', '~> 2.3.8'
2
1
  require File.expand_path('../test_helper', __FILE__)
3
2
 
4
3
  require 'oauth/request_proxy/action_controller_request'
5
- require 'action_controller/test_process'
6
4
 
7
- class ActionControllerRequestProxyTest < Test::Unit::TestCase
5
+ class ActionControllerRequestProxyTest < Minitest::Test
8
6
 
9
7
  def request_proxy(request_method = :get, uri_params = {}, body_params = {})
10
- request = ActionController::TestRequest.new
11
- request.set_REQUEST_URI('/')
8
+ request = ActionDispatch::TestRequest.new
9
+ request.request_uri = '/'
12
10
 
13
11
  case request_method
14
12
  when :post
15
13
  request.env['REQUEST_METHOD'] = 'POST'
16
14
  when :put
17
15
  request.env['REQUEST_METHOD'] = 'PUT'
16
+ when :patch
17
+ request.env['REQUEST_METHOD'] = 'PATCH'
18
18
  end
19
19
 
20
20
  request.env['REQUEST_URI'] = '/'
@@ -50,6 +50,14 @@ class ActionControllerRequestProxyTest < Test::Unit::TestCase
50
50
  assert_equal 'PUT', request_proxy.method
51
51
  end
52
52
 
53
+ def test_that_proxy_simple_patch_request_works_with_query_params
54
+ request_proxy = request_proxy(:patch, {'key'=>'value'})
55
+
56
+ expected_parameters = [["key", "value"]]
57
+ assert_equal expected_parameters, request_proxy.parameters_for_signature
58
+ assert_equal 'PATCH', request_proxy.method
59
+ end
60
+
53
61
  def test_that_proxy_simple_get_request_works_with_post_params
54
62
  request_proxy = request_proxy(:get, {}, {'key'=>'value'})
55
63
 
@@ -74,6 +82,14 @@ class ActionControllerRequestProxyTest < Test::Unit::TestCase
74
82
  assert_equal 'PUT', request_proxy.method
75
83
  end
76
84
 
85
+ def test_that_proxy_simple_patch_request_works_with_post_params
86
+ request_proxy = request_proxy(:patch, {}, {'key'=>'value'})
87
+
88
+ expected_parameters = []
89
+ assert_equal expected_parameters, request_proxy.parameters_for_signature
90
+ assert_equal 'PATCH', request_proxy.method
91
+ end
92
+
77
93
  def test_that_proxy_simple_get_request_works_with_mixed_params
78
94
  request_proxy = request_proxy(:get, {'key'=>'value'}, {'key2'=>'value2'})
79
95
 
@@ -98,6 +114,14 @@ class ActionControllerRequestProxyTest < Test::Unit::TestCase
98
114
  assert_equal 'PUT', request_proxy.method
99
115
  end
100
116
 
117
+ def test_that_proxy_simple_patch_request_works_with_mixed_params
118
+ request_proxy = request_proxy(:patch, {'key'=>'value'}, {'key2'=>'value2'})
119
+
120
+ expected_parameters = [["key", "value"]]
121
+ assert_equal expected_parameters, request_proxy.parameters_for_signature
122
+ assert_equal 'PATCH', request_proxy.method
123
+ end
124
+
101
125
  def test_parameter_keys_should_preserve_brackets_from_hash
102
126
  assert_equal(
103
127
  [["message[body]", "This is a test"]],
@@ -1,12 +1,11 @@
1
1
  require File.expand_path('../test_helper', __FILE__)
2
- require 'mocha'
3
2
 
4
3
  require 'stringio'
5
4
 
6
5
  # This performs testing against Andy Smith's test server http://term.ie/oauth/example/
7
6
  # Thanks Andy.
8
7
  # This also means you have to be online to be able to run these.
9
- class ConsumerTest < Test::Unit::TestCase
8
+ class ConsumerTest < Minitest::Test
10
9
  def setup
11
10
  @consumer=OAuth::Consumer.new(
12
11
  'consumer_key_86cad9', '5888bf0345e5d237',
@@ -132,7 +131,14 @@ class ConsumerTest < Test::Unit::TestCase
132
131
  assert_equal :post,@consumer.http_method
133
132
  end
134
133
 
135
- def test_that_token_response_should_be_uri_parameter_format_as_default
134
+ def test_token_request_identifies_itself_as_a_token_request
135
+ request_options = {}
136
+ @consumer.stubs(:request).returns(create_stub_http_response)
137
+ @consumer.token_request(:post, '/', 'token', request_options) {}
138
+ assert_equal true, request_options[:token_request]
139
+ end
140
+
141
+ def test_that_token_response_should_be_uri_parameter_format_as_default
136
142
  @consumer.expects(:request).returns(create_stub_http_response("oauth_token=token&oauth_token_secret=secret"))
137
143
 
138
144
  hash = @consumer.token_request(:get, "")
@@ -6,7 +6,7 @@ require 'oauth/request_proxy/curb_request'
6
6
  require 'curb'
7
7
 
8
8
 
9
- class CurbRequestProxyTest < Test::Unit::TestCase
9
+ class CurbRequestProxyTest < Minitest::Test
10
10
 
11
11
  def test_that_proxy_simple_get_request_works
12
12
  request = Curl::Easy.new('/test?key=value')
@@ -3,7 +3,7 @@ begin
3
3
 
4
4
  require 'oauth/client/em_http'
5
5
 
6
- class EmHttpClientTest < Test::Unit::TestCase
6
+ class EmHttpClientTest < Minitest::Test
7
7
 
8
8
  def setup
9
9
  @consumer = OAuth::Consumer.new('consumer_key_86cad9', '5888bf0345e5d237')
@@ -6,7 +6,7 @@ require 'em-http'
6
6
  require 'oauth/request_proxy/em_http_request'
7
7
 
8
8
 
9
- class EmHttpRequestProxyTest < Test::Unit::TestCase
9
+ class EmHttpRequestProxyTest < Minitest::Test
10
10
 
11
11
  def test_request_proxy_works_with_simple_request
12
12
  proxy = create_request_proxy
@@ -1,13 +1,18 @@
1
- require 'test/unit'
2
1
  require 'rubygems'
2
+ require 'minitest/autorun'
3
+ require 'mocha/mini_test'
4
+ require 'rack/test'
5
+
6
+ ENV['RACK_ENV'] = 'test'
7
+
8
+ require 'byebug'
3
9
 
4
10
  $LOAD_PATH << File.dirname(__FILE__) + '/../lib/'
5
11
  require 'oauth'
6
- require 'mocha'
7
12
  require 'stringio'
8
13
  require 'webmock'
9
14
 
10
- class Test::Unit::TestCase
15
+ class Minitest::Test
11
16
  include WebMock::API
12
17
 
13
18
  def assert_matching_headers(expected, actual)
@@ -1,6 +1,6 @@
1
1
  require File.expand_path('../test_helper', __FILE__)
2
2
 
3
- class TestSignatureHmacSha1 < Test::Unit::TestCase
3
+ class TestSignatureHmacSha1 < Minitest::Test
4
4
  def test_that_hmac_sha1_implements_hmac_sha1
5
5
  assert OAuth::Signature.available_methods.include?('hmac-sha1')
6
6
  end
@@ -1,6 +1,6 @@
1
1
  require File.expand_path('../test_helper', __FILE__)
2
2
 
3
- class NetHTTPClientTest < Test::Unit::TestCase
3
+ class NetHTTPClientTest < Minitest::Test
4
4
 
5
5
  def setup
6
6
  @consumer = OAuth::Consumer.new('consumer_key_86cad9', '5888bf0345e5d237')
@@ -62,6 +62,12 @@ class NetHTTPClientTest < Test::Unit::TestCase
62
62
  assert_matching_headers "oauth_nonce=\"225579211881198842005988698334675835446\", oauth_body_hash=\"oXyaqmHoChv3HQ2FCvTluqmAC70%3D\", oauth_signature_method=\"HMAC-SHA1\", oauth_token=\"token_411a7f\", oauth_timestamp=\"1199645624\", oauth_consumer_key=\"consumer_key_86cad9\", oauth_signature=\"0DA6pGTapdHSqC15RZelY5rNLDw%3D\", oauth_version=\"1.0\"", request['authorization']
63
63
  end
64
64
 
65
+ def test_that_body_hash_is_obmitted_when_token_request
66
+ request = Net::HTTP::Post.new(@request_uri.path)
67
+ request.oauth!(@http, @consumer, @token, {:nonce => @nonce, :timestamp => @timestamp, :token_request => true})
68
+ assert_no_match(/oauth_body_hash/, request['authorization'])
69
+ end
70
+
65
71
  def test_that_body_hash_is_obmitted_when_no_algorithm_is_defined
66
72
  request = Net::HTTP::Post.new(@request_uri.path)
67
73
  request.body = "data"
@@ -1,6 +1,6 @@
1
1
  require File.expand_path('../test_helper', __FILE__)
2
2
 
3
- class NetHTTPRequestProxyTest < Test::Unit::TestCase
3
+ class NetHTTPRequestProxyTest < Minitest::Test
4
4
 
5
5
  def test_that_proxy_simple_get_request_works
6
6
  request = Net::HTTP::Get.new('/test?key=value')
@@ -1,6 +1,6 @@
1
1
  require File.expand_path('../test_helper', __FILE__)
2
2
 
3
- class TestOAuthHelper < Test::Unit::TestCase
3
+ class TestOAuthHelper < Minitest::Test
4
4
 
5
5
  def test_parse_valid_header
6
6
  header = 'OAuth ' \
@@ -27,7 +27,7 @@ class TestOAuthHelper < Test::Unit::TestCase
27
27
  def test_parse_header_ill_formed
28
28
  header = "OAuth garbage"
29
29
 
30
- assert_raise OAuth::Problem do
30
+ assert_raises OAuth::Problem do
31
31
  OAuth::Helper.parse_header(header)
32
32
  end
33
33
  end
@@ -42,7 +42,7 @@ class TestOAuthHelper < Test::Unit::TestCase
42
42
  'oauth_timestamp="1240004133", oauth_nonce="nonce", ' \
43
43
  'oauth_version="1.0" '
44
44
 
45
- assert_raise OAuth::Problem do
45
+ assert_raises OAuth::Problem do
46
46
  OAuth::Helper.parse_header(header)
47
47
  end
48
48
  end
@@ -68,7 +68,7 @@ class TestOAuthHelper < Test::Unit::TestCase
68
68
  assert_equal "nonce", params['oauth_nonce']
69
69
  assert_equal "1.0", params['oauth_version']
70
70
  end
71
-
71
+
72
72
  def test_normalize
73
73
  params = {
74
74
  'oauth_nonce' => 'nonce',
@@ -81,7 +81,7 @@ class TestOAuthHelper < Test::Unit::TestCase
81
81
  }
82
82
  assert_equal("oauth_consumer_key=vince_clortho&oauth_nonce=nonce&oauth_signature_method=HMAC-SHA1&oauth_timestamp=1240004133&oauth_token=token_value&oauth_version=1.0&weight%5Bvalue%5D=65", OAuth::Helper.normalize(params))
83
83
  end
84
-
84
+
85
85
  def test_normalize_nested_query
86
86
  assert_equal([], OAuth::Helper.normalize_nested_query({}))
87
87
  assert_equal(["foo=bar"], OAuth::Helper.normalize_nested_query({:foo => 'bar'}))