def test_get_evernote_client(self): from oauth.views import get_token from oauth.views import get_evernote_client token = get_token(username='******') client = get_evernote_client(token=token) self.assertEqual(client.token, u"S=s1:U=91a50:E=158f7ee9efa:C=151a03d7140:P=185:A=koichi-ezato-3816:V=2:H=1a4e5efcc8f63951e17852d0c8019cab") self.assertEqual(client.consumer_key, None) self.assertEqual(client.consumer_secret, None) self.assertEqual(client.additional_headers, {}) self.assertEqual(client.sandbox, True) self.assertEqual(client.secret, None) self.assertEqual(client.service_host, 'sandbox.evernote.com')
def test_get_token(self): from oauth.views import get_token token = get_token(username='******') self.assertEqual(token, u"S=s1:U=91a50:E=158f7ee9efa:C=151a03d7140:P=185:A=koichi-ezato-3816:V=2:H=1a4e5efcc8f63951e17852d0c8019cab")