本文整理汇总了Python中oic.oauth2.Client.client_id方法的典型用法代码示例。如果您正苦于以下问题:Python Client.client_id方法的具体用法?Python Client.client_id怎么用?Python Client.client_id使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类oic.oauth2.Client
的用法示例。
在下文中一共展示了Client.client_id方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: test_get_authorization_request
# 需要导入模块: from oic.oauth2 import Client [as 别名]
# 或者: from oic.oauth2.Client import client_id [as 别名]
def test_get_authorization_request():
client = Client()
client.redirect_uris = ["https://www.example.com/authz"]
client.client_id = "a1b2c3"
args = {"response_type": ["code"]}
ar = client.construct_AuthorizationRequest(request_args=args)
assert ar["client_id"] == "a1b2c3"
assert ar["redirect_uri"] == "https://www.example.com/authz"
assert ar["response_type"] == ["code"]
client = Client()
client.client_id = "a1b2c3"
args = {"response_type": ["code"], "redirect_uri": "https://www.example.com/authz"}
ar = client.construct_AuthorizationRequest(request_args=args)
assert ar["client_id"] == "a1b2c3"
assert ar["redirect_uri"] == "https://www.example.com/authz"
assert ar["response_type"] == ["code"]