commit a280d2e88c7a732630a5ae00c2c452c6db34cc8b
Author: Matt Riedemann <email address hidden>
Date: Sun Jul 31 18:34:57 2016 -0400
Straddle python-neutronclient 5.0 for testing
python-neutronclient 5.0 has deprecated the usage of
tenant_id/tenant_name in place of project_id/project_name
for keystone v3 usage. It does this using debtcollector
decorators on the methods with those kwargs. This is fine
at runtime but doesn't work with mox since mox stubs the
methods off the Client class, but doesn't pick up and stub
any decorators on those methods. So when our unit tests
pass tenant_id kwargs they fail on the moxed_client.
To make the tests work for both neutronclient>5 and <5 we
simply pass the project_id as an arg rather than kwarg
to the show_quota method.
Reviewed: https:/ /review. openstack. org/349297 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=a280d2e88c7 a732630a5ae00c2 c452c6db34cc8b
Committed: https:/
Submitter: Jenkins
Branch: master
commit a280d2e88c7a732 630a5ae00c2c452 c6db34cc8b
Author: Matt Riedemann <email address hidden>
Date: Sun Jul 31 18:34:57 2016 -0400
Straddle python- neutronclient 5.0 for testing
python- neutronclient 5.0 has deprecated the usage of id/tenant_ name in place of project_ id/project_ name
tenant_
for keystone v3 usage. It does this using debtcollector
decorators on the methods with those kwargs. This is fine
at runtime but doesn't work with mox since mox stubs the
methods off the Client class, but doesn't pick up and stub
any decorators on those methods. So when our unit tests
pass tenant_id kwargs they fail on the moxed_client.
To make the tests work for both neutronclient>5 and <5 we
simply pass the project_id as an arg rather than kwarg
to the show_quota method.
Change-Id: I86bbac3e24bef2 7396297dfc79eb2 4c61dbcb6ac
Closes-Bug: #1608258