summaryrefslogtreecommitdiff
path: root/keystoneclient/tests/utils.py
Commit message (Collapse)AuthorAgeFilesLines
* Remove redundant default value None for dict.getZhiQiang Fan2014-02-221-1/+1
| | | | | | The default value for dict.get is None, no need to specify again. Change-Id: I9f0204e59bd4c1642586bddfef0c75e0a7730925
* Merge "Remove vim header"Jenkins2014-02-131-2/+0
|\
| * Remove vim headerEric Guo2014-02-081-2/+0
| | | | | | | | | | | | | | | | We don't need vim modelines in each source file, it can be set in user's vimrc. Change-Id: Ic7a61430a0a320ce6b0c4518d9f5d988e35f8aae Closes-Bug: #1229324
* | Merge "Add back --insecure option to CURL debug"Jenkins2014-02-121-0/+3
|\ \
| * | Add back --insecure option to CURL debugJamie Lennox2014-02-041-0/+3
| |/ | | | | | | | | | | | | | | This was added in review: https://review.openstack.org/#/c/53500 but lost in the conversion to using session. Add it back again. Change-Id: Ia063eb018d3a7da706a02d60df63bfa1be21d147 Related-Bug: #1249891
* | Python3: httpretty.last_request().body is now bytesCyril Roelandt2014-02-081-2/+6
|/ | | | | | In Python 3, we must decode it before using it. Change-Id: I473ba7b9732555ef5f9011a50d8684260e1f7f71
* Consistently support kwargs across all v3 CRUD Manager opsDivyesh Khandeshi2014-01-221-0/+8
| | | | | | | Co-Authored-By: Saju Madhavan <sajuptpm@gmail.com> Closes-Bug: 1047867 Implements: blueprint extensible-crud-manager-operations Change-Id: I64e11bcf3797eb84e4695605daea9749259d78ec
* Make assertQueryStringIs usage simplerSteven Hardy2014-01-131-2/+8
| | | | | | | | As requested in https://review.openstack.org/#/c/65728/, this "fixes" assertQueryStringIs so it takes a query string, rather than a dict of lists, which is a less convenient format in many tests. Change-Id: Ib4c49ba71f7e12bb5bcb4dfde77974f3418c7854
* Merge "Python 3: Use HTTPMessage.get() rather than HTTPMessage.getheader()"Jenkins2014-01-111-1/+1
|\
| * Python 3: Use HTTPMessage.get() rather than HTTPMessage.getheader()Cyril Roelandt2014-01-101-1/+1
| | | | | | | | | | | | | | | | In Python 2, get() is a synonym for getheader(), which does not exist in Python 3. Closes-Bug: #1267987 Change-Id: I6989a6ea733e0a186e9e68a61aaa8c3e43a198a6
* | Avoid meaningless comparison that leads to a TypeErrorCyril Roelandt2013-12-161-1/+1
|/ | | | | | | | | | | | The "requests" module tries to do this comparison in raise_for_status(): 400 <= self.status_code < 500 with "self.status_code" being "None". In Python2, it's a valid comparison, but in Python3, it triggers a TypeError. We fix it by giving a valid default value to "self.status_code". Change-Id: I9ea9ecfb698546a7f6526464aa528441bb7c1ccd
* Add AssertRequestHeaderEqual test helper and make use of itJamie Lennox2013-10-161-0/+9
| | | | | | | This will be a fairly common pattern and so should be a helper of its own. Change-Id: Ic06add6dfe40c7d3ab88dfdd99a9087fdebd9b67
* Allow v2 client authentication with trust_idSteven Hardy2013-09-261-0/+1
| | | | | | | | | | | | | | | | | | | It should be possible to authenticate against the v2 tokens API with a trust_id, because it suports rescoping an existing token to a trust, this patch adds client support for this. Note with the current keystone code it's necessary to pass the trustor tenant ID when rescoping with a trust where impersonation==True, e.g: c = client_v2.Client(username=TRUSTEE_USERNAME, password=TRUSTEE_USERNAME, tenant_name=TRUSTEE_TENANT_NAME, auth_url=OS_AUTH_URL_V2) c.authenticate(trust_id=trust_i.id, tenant_id=TRUSTOR_TENANT_ID) Change-Id: I177c41af298b7437e2c6fb437aa9ce9a09773b9d Closes-Bug: #1231483
* Move tests in keystoneclientJamie Lennox2013-09-241-0/+117
This is the suggested location for tests and is adopted by most projects. As part of this change relative imports to package imports. Fix all the test running and coverage code to point to the new location. Change-Id: I01264aed14f396ab9a7242e3e72b71e1bc332675