diff options
| author | Hsiaoming Yang <me@lepture.com> | 2015-07-02 15:04:37 +0800 |
|---|---|---|
| committer | Hsiaoming Yang <me@lepture.com> | 2015-07-02 17:24:35 +0800 |
| commit | db602c837436790cf4a98744fa66f4dd20de7f79 (patch) | |
| tree | 8217fc23332b3dc6260b6ca6fbc2109b407304ea /tests | |
| parent | 674543558fa95c41285b874390a54f28e36983a9 (diff) | |
| download | oauthlib-db602c837436790cf4a98744fa66f4dd20de7f79.tar.gz | |
Add tests when Request body has password
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/test_common.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/test_common.py b/tests/test_common.py index 9c75bbd..eadd79a 100644 --- a/tests/test_common.py +++ b/tests/test_common.py @@ -185,6 +185,15 @@ class RequestTest(TestCase): with self.assertRaises(AttributeError): getattr(r, 'does_not_exist') + def test_password_body(self): + payload = 'username=foo&password=bar' + r = Request(URI, body=payload) + self.assertNotIn('bar', repr(r)) + + payload = 'password=bar&username=foo' + r = Request(URI, body=payload) + self.assertNotIn('bar', repr(r)) + class CaseInsensitiveDictTest(TestCase): |
