summaryrefslogtreecommitdiffstats
path: root/snaps/openstack/utils/tests/keystone_utils_tests.py
AgeCommit message (Collapse)AuthorFilesLines
2017-11-20Refactoring of UserSettings to extend UserConfigspisarski1-3/+3
UserSettings and keystone_utils have a runtime cyclical dependency. This patch reduces this dependency and deprecates the UserSettings class. JIRA: SNAPS-226 Change-Id: Ifcc2a029463780e963b1afcf1de31baf9edded40 Signed-off-by: spisarski <s.pisarski@cablelabs.com>
2017-11-20Refactoring of ProjectSettings to extend ProjectConfigspisarski1-3/+3
ProjectSettings and keystone_utils have a runtime cyclical dependency. This patch reduces this dependency and deprecates the ProjectSettings class. JIRA: SNAPS-221 Change-Id: I9e39f09fb8bb03dbd725f44b7256bacb05f26afc Signed-off-by: spisarski <s.pisarski@cablelabs.com>
2017-08-07Refactored neutron_utils#get_security_group()spisarski1-2/+2
Added a sec_grp_settings (SecurityGroupSettings) object parameter in addition to sec_grp_name for more robust query options. JIRA: SNAPS-164 Change-Id: I8bb21ff9e5e6b1f532773ca01d37964f8b47b530 Signed-off-by: spisarski <s.pisarski@cablelabs.com>
2017-08-03Delete 'default' security group associated to new projects.spisarski1-2/+13
OpenStack can create a security group named 'default' each time a new project/tenant has been created but is not cleaned up when the project has been deleted. This patch adds this functionality into OpenStackProject#clean() method. Also added similar routine to KeystoneUtilsTests#tearDown() method. JIRA: SNAPS-169 Change-Id: I29492ae2ddd82e7d59d09b9c4eb759be4835532a Signed-off-by: spisarski <s.pisarski@cablelabs.com>
2017-08-03Add domain name when creating projects and usersLinda Wang1-6/+16
(spisarski) Also clarified the difference between domain ID and name Added helper methods and domain object for Domains JIRA: FUNCTEST-858 Change-Id: Iccd7eef56713a4ad0c23232073f52bc71168bf5c Signed-off-by: Linda Wang <wangwulin@huawei.com>
2017-07-31Changed keystone_utils#get_project to accept settingsspisarski1-1/+1
Added project_settings parameter to allow for more robust queries based on the known settings as required. JIRA: SNAPS-159 Change-Id: I56ecf0cc34bbb91c4cfe2afe83971b614ec80a39 Signed-off-by: spisarski <s.pisarski@cablelabs.com>
2017-07-17Last task necessary to stop users from easily obtaining OS objects.spisarski1-1/+1
Changed external interfaces still exposing OpenStack created APIs to either return SNAPS-OO domain objects or objects contained on the OpenStack generated objects as to not leak implementation details that would eventually break the library when new API versions are released. JIRA: SNAPS-125 Change-Id: Iab6d6d298c4c5da68daed4b1b252313a1595a295 Signed-off-by: spisarski <s.pisarski@cablelabs.com>
2017-07-13Created domain class for roles.spisarski1-1/+1
Create Role domain class so keystone_utils.py functions returning role objects will not be leaking out implementation details as each API version can change these data structures and this should all be handled by the SNAPS neutron utility. JIRA: SNAPS-119 Change-Id: I6918a45c1c414ee6b104ec36e63c540d6f656e30 Signed-off-by: spisarski <s.pisarski@cablelabs.com>
2017-07-12Fix the unittest of get_endpointLinda Wang1-5/+5
The endpoints according to interface may be same or different on different deployment, which depends on the configuration during the deployment. Change-Id: Id2127a3c3fe0eca4b10a98c548d10391912f9610 Signed-off-by: Linda Wang <wangwulin@huawei.com>
2017-07-11Added ability to add a user to a role.spisarski1-3/+35
This functionality was requested as the SNAPS-OO integration tests currently have the ability to run these tests in custom projects with custom users and certain OpenStack installations are not allowing some of the integration tests functions unless the new user has been added to the 'admin' role. Change-Id: I255cfa089a14bbcb434a6cd33b2a1dfae66206b5 Signed-off-by: spisarski <s.pisarski@cablelabs.com>
2017-07-07Fix get_endpointLinda Wang1-3/+21
One specific service type has the same endpoint url if interface is admin or internal, while it is different from that with public interface, except the admin and internal endpoint url for service identity has same ip but different ports. Change-Id: I19c260222286d8b4aa3f0d3b7d273e192b13a96b Signed-off-by: Linda Wang <wangwulin@huawei.com>
2017-07-05Making test user password dynamic for testing against secure pods.spisarski1-1/+2
Change-Id: I7c281062fc89a2ff4721e6bee9e90042c59273c5 Signed-off-by: spisarski <s.pisarski@cablelabs.com>
2017-07-05Refactor OSCreds to leverage kwargs instead of named parameters.spisarski1-9/+17
JIRA: SNAPS-109 Change-Id: I423ede964cce9fc3b4e5b27f1e8f0dd7603d9ff1 Signed-off-by: spisarski <s.pisarski@cablelabs.com>
2017-06-01Refactor keystone endpoint tests to the proper test class.spisarski1-26/+26
Also added documentation for those three tests. Change-Id: I38a728ba9e258a821341621978953e0529a0c1a1 Signed-off-by: spisarski <s.pisarski@cablelabs.com>
2017-05-19Add the function of getting endpointLinda Wang1-0/+26
Functest is trying to leverage SNAPS-OO library to replace some utility functions, in which def get_endpoint is called by testcases onos, odl, multisite and cloudify_ims. JIRA: SNAPS-78 Change-Id: Icb2778e0337a5d4246762ac3037773b39d5d554d Signed-off-by: Linda Wang <wangwulin@huawei.com>
2017-05-08Modified code to support both Python 2.7 and 3.xspisarski1-3/+3
* Tested on Python 2.7.10 and 3.4.4 * Updated installation documentation JIRA: SNAPS-30 Change-Id: I94a37d218be8ea47bbbcfb560197737430fcb3ba Signed-off-by: spisarski <s.pisarski@cablelabs.com>
2017-02-15Initial patch with all code from CableLabs repository.spisarski1-0/+100
Change-Id: I70a2778718c5e7f21fd14e4ad28c9269d3761cc7 Signed-off-by: spisarski <s.pisarski@cablelabs.com>