Skip to content

Commit 390ae74

Browse files
author
Simple Geebus
committed
Merge commit 'd8fdecb8e844b4b08be35967e0797360d8ce0a3a'
2 parents b330ce8 + d8fdecb commit 390ae74

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

tests/test_oauth.py

+11
Original file line numberDiff line numberDiff line change
@@ -545,6 +545,17 @@ def test_get_normalized_parameters_empty(self):
545545

546546
self.assertEquals(expected, res)
547547

548+
def test_get_normalized_parameters_duplicate(self):
549+
url = "http://example.com/v2/search/videos?oauth_nonce=79815175&oauth_timestamp=1295397962&oauth_consumer_key=mykey&oauth_signature_method=HMAC-SHA1&q=car&oauth_version=1.0&offset=10&oauth_signature=spWLI%2FGQjid7sQVd5%2FarahRxzJg%3D"
550+
551+
req = oauth.Request("GET", url)
552+
553+
res = req.get_normalized_parameters()
554+
555+
expected='oauth_consumer_key=mykey&oauth_nonce=79815175&oauth_signature=spWLI%2FGQjid7sQVd5%2FarahRxzJg%3D&oauth_signature_method=HMAC-SHA1&oauth_timestamp=1295397962&oauth_version=1.0&offset=10&q=car'
556+
557+
self.assertEquals(expected, res)
558+
548559
def test_get_normalized_parameters_from_url(self):
549560
# example copied from
550561
# https://github.com/ciaranj/node-oauth/blob/master/tests/oauth.js

0 commit comments

Comments
 (0)