summaryrefslogtreecommitdiff
path: root/openstackclient/tests
Commit message (Collapse)AuthorAgeFilesLines
* Merge "Add unit tests for "host list" and "host show" commands"Jenkins2016-07-212-1/+111
|\
| * Add unit tests for "host list" and "host show" commandsHuanxuan Ao2016-06-272-1/+111
| | | | | | | | | | | | | | Missing unit tests for "host list" and "host show" commands in computev2, this patch add them. Change-Id: Ib157920fa2267ec96d206cdf46213563a105501b
* | Merge "Implement rbac list and show command"Jenkins2016-07-202-0/+173
|\ \
| * | Implement rbac list and show commandting wang2016-06-272-0/+173
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1. implement "openstack network rbac list" 2. implement "openstack network rbac show" 3. also add FakeRBACPolicy to test "network rbac xxx" command The unit test class similar to FakeRouter, which is able to fake one or more rbac policies. It will be used by the rbac CRUD patches. Change-Id: I6c97bc8819698546895fd530464a2cbb347bf77d Co-Authored-By: Huanxuan Ao <huanxuan.ao@easystack.cn> Partially-Implements: blueprint neutron-client-rbac Depends-On: I88f409a24947b67146c0f93ec8480834cef56d2f
* | | Merge "Add port security option to network commands"Jenkins2016-07-202-0/+21
|\ \ \
| * | | Add port security option to network commandsRichard Theis2016-06-292-0/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add the "--enable-port-security" and "--disable-port-security" options to the "network create" and "network set" commands. This supports setting the default port security for ports created on a network. Change-Id: I1deb505bd77cef2e4bc3c2dbbb0c450665136f47 Implements: blueprint neutron-client
* | | | Exchange the check order for the dhcp and no-dhcpqtang2016-07-191-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The dhcp is setting with True by default and progress always jump into the first if check. So the no-dhcp option always ignored there. Check the no-dhcp option first and then the dhcp option value to avoid this. Change-Id: Ide640e2cab3936d419ca62105304ff5d4a8a2074 Closes-Bug: #1602588
* | | | Support bulk deletion for delete commands in identityv3Huanxuan Ao2016-07-199-9/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Support bulk deletion for delete commands in the list below identity/v3/consumer identity/v3/credential identity/v3/domain identity/v3/ec2creds identity/v3/endpoint identity/v3/federation_protocol identity/v3/identity_provider identity/v3/mapping identity/v3/policy identity/v3/region identity/v3/service_provider identity/v3/service The unit test in identityv3 need to be refactored, so I add some functional tests instead. I will add all unit tests at one time after the refactor completed. Change-Id: I82367570f59817b47c87b6c7bfeae95ccfe5c50e Closes-Bug: #1592906
* | | | Merge "Add create_one_image_member() in FakeImage class and update test"Jenkins2016-07-182-13/+32
|\ \ \ \
| * | | | Add create_one_image_member() in FakeImage class and update testHuanxuan Ao2016-07-152-13/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Usually we use a fake object in unit test. To match the other test, add create_one_image_member() in FakeImage class in imagev2 to create a fake image member, delete the old data and update the unit test of image. Change-Id: I062a362b15db7e8bc89ec48c540d310199fd6c0b
* | | | | Merge "Support error handling for delete commands in volumev2"Jenkins2016-07-185-22/+273
|\ \ \ \ \
| * | | | | Support error handling for delete commands in volumev2Huanxuan Ao2016-07-145-22/+273
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some delete conmmands in volumev2 did not support error handling, this patch add them and also add the unit tests for bulk deletion Change-Id: I56ade6f9c7396c78fb989547476c4d94ccd76eae
* | | | | | Merge "Make set/unset commands pass normally when nothing specified in ↵Jenkins2016-07-185-7/+32
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | identityv3"
| * | | | | | Make set/unset commands pass normally when nothing specified in identityv3Huanxuan Ao2016-07-145-7/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I554b41969f96b62a2c6d37024caa56b1441d5ed1 Partial-bug: #1588588
* | | | | | | Merge "Add "--project" option to "volume type create" command"Jenkins2016-07-181-0/+20
|\ \ \ \ \ \ \
| * | | | | | | Add "--project" option to "volume type create" commandHuanxuan Ao2016-07-121-0/+20
| |/ / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add "--project" and "--project-domain" options to "volume type create" command. We can use these options to add the type access to a given project when we create the volume type. Change-Id: I483a6b61dae137682c3d1f7527531b40e508ba92 Closes-Bug: #1602169
* | | | | | | Merge "image list: Add Checksum column"Jenkins2016-07-182-0/+4
|\ \ \ \ \ \ \
| * | | | | | | image list: Add Checksum columnMarc Abramowitz2016-07-112-0/+4
| |/ / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The checksum could potentially be useful for spotting duplicated images or checking if images with the same name are identical or different. Closes-Bug: #1602073 Change-Id: Ia0c41970c846d550de14297e18bc738e847e5a3b
* | | | | | | Merge "Pass security group id to novaclient"Jenkins2016-07-181-0/+53
|\ \ \ \ \ \ \ | |_|_|/ / / / |/| | | | | |
| * | | | | | Pass security group id to novaclientRajasi Kulkarni2016-07-111-0/+53
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In RemoveServerSecurityGroup we currently pass the entire security group object, which results in TypeError in novaclient. Added unit test case to test command 'openstack server remove security group -h <server> <group>' Change-Id: I6d486403a83804c3a30d6f89d2cf7f64f09797c6 Closes-Bug: 1590883
* | | | | | | Merge "Change to plural form of object in multi delete error message in ↵Jenkins2016-07-143-6/+6
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | networkv2"
| * | | | | | | Change to plural form of object in multi delete error message in networkv2Huanxuan Ao2016-07-143-6/+6
| | |_|/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Usually, the error message of multi delete is: "'result' of 'total' 'objects' failed to delete" the objects is a plural form. To match the other multi delete error messages in OSC, change the object in delete error message in networkv2 to a plural form. Just add a 's' in the message. Change-Id: I17e0735d025bb61014db709d2639813565015b3d
* | | | | | | Merge "Modify compute agent set command"Jenkins2016-07-141-9/+64
|\ \ \ \ \ \ \ | |/ / / / / / |/| | | | | |
| * | | | | | Modify compute agent set commandsunyajing2016-07-111-9/+64
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Migrate ``compute agent set`` arguments: version, url, md5hash to be optional. BackwardsIncompatibleImpact Change-Id: I092b7ed24274bafa548f0537c4586504be3a2825 Co-Authored-By: Huanxuan Ao <huanxuan.ao@easystack.cn>
* | | | | | | Merge "Use FakeProject and FakeDomain classes in unit tests of networkv2"Jenkins2016-07-147-121/+77
|\ \ \ \ \ \ \
| * | | | | | | Use FakeProject and FakeDomain classes in unit tests of networkv2Huanxuan Ao2016-07-117-121/+77
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | FakeProject and FakeDomain classes have been completed in identityv2_0 and v3, Now we can use these classes instead of old test data in networkv2. Change-Id: I2f698e54ff35e24ffbdcaba29da6f96eb263cc0a Partially-Implements: blueprint use-fake-project
* | | | | | | | Change the wrong import orderHuanxuan Ao2016-07-121-1/+2
| |_|_|/ / / / |/| | | | | | | | | | | | | | | | | | | | Change-Id: Ia48f0aae0250a5d29c0f6fa46386465e118f760f
* | | | | | | Merge "Add "--incremental" option to "backup create" command in volume v2"Jenkins2016-07-111-0/+4
|\ \ \ \ \ \ \
| * | | | | | | Add "--incremental" option to "backup create" command in volume v2Paul Bourke2016-07-111-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Cinder V2 API supports creating volume backup with "--incremental" option. However, OSC doesn't support this argument. So this patch adds the "--incremental" option to allow users to create incremental style backups. Change-Id: Iefac5f1a6c9ef006ad9c22d4250ae6df50504781 Closes-Bug: 1600196
* | | | | | | | Merge "Unskip tests caused by bug 1599333"Jenkins2016-07-114-18/+24
|\ \ \ \ \ \ \ \ | |/ / / / / / / |/| | | | | | |
| * | | | | | | Unskip tests caused by bug 1599333Steve Martinelli2016-07-074-18/+24
| |/ / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There is now a second .get() call in osc_lib.utils.find_resources. These tests were failing because they only mocked a single access call to .get(). Ensure there are two calls to .get(), with the first one raising an exception. Change-Id: Idd2ad4a27a6db5bee633cc37a1042dbb0a57aa71 Closes-Bug: #1599333
* | | | | | | Remove FakeService.get_serviceszheng yin2016-07-091-20/+0
| |_|/ / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | FakeService.get_services is useless in other test files, so remove it Change-Id: If90b8742be97697f285750a05896b574c45f3504
* | | | | | Add notes, modify notes in fakes docstringzheng yin2016-07-081-6/+17
|/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some code has no notes, then add them Some code notes are not perfect, then improve them Some code notes are incorrect, then modify them Change-Id: I43f9a8663ae138bdd494bc234c1fac00c2dd6c95
* | | | | Merge "osc-lib: api.auth"Jenkins2016-07-071-2/+2
|\ \ \ \ \
| * | | | | osc-lib: api.authDean Troyer2016-06-301-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Move auth plugin checking to osc-lib. Change-Id: I673d9c2d6e8bbf724c3000459a729e831d747814
* | | | | | modify notes in the FakeHypervisorStats docstringzheng yin2016-07-071-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The arugments should be: count and current_workload Change-Id: I445d1d72d1f1b86a626bb4c9512cdb8311b2ebc9
* | | | | | Merge "Add "--property" option to "snapshot create" command in volumev2"Jenkins2016-07-061-2/+7
|\ \ \ \ \ \
| * | | | | | Add "--property" option to "snapshot create" command in volumev2Huanxuan Ao2016-07-061-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add "--property" option to "snapshot create" command in volumev2 (v2 only) to support adding properties to a new snapshot. Change-Id: Ie0e90c9ccc2ac89b3b7b0ac89751fd864aada9a4 Closes-Bug: #1597192
* | | | | | | Merge "Add '--force' option to 'backup delete' command in volumev2"Jenkins2016-07-061-1/+17
|\ \ \ \ \ \ \
| * | | | | | | Add '--force' option to 'backup delete' command in volumev2Huanxuan Ao2016-07-061-1/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add '--force' option to 'backup delete' command in volumev2 (v2 only) to allow delete in state other than error or available. Change-Id: I661ea0d465db227e374cbacdde0206fa1a6dd3d5 Closes-Bug: #1597188
* | | | | | | | Merge "Transfer "ip fixed add/remove" to "server add/remove fixed ip""Jenkins2016-07-061-0/+71
|\ \ \ \ \ \ \ \
| * | | | | | | | Transfer "ip fixed add/remove" to "server add/remove fixed ip"Tang Chen2016-07-041-0/+71
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch does the following things to transfer "ip fixed add/remove" to "server add/remove fixed ip": * Add new command "server add/remove fixed ip", and unit tests and doc. * Deprecate "ip fixed add/remove" command. compute/v2/fixedip.py is not removed because the arguments' positions are different between the new and old commands. * ip fixed add <network> <server> server add fixed ip <server> <network> * ip fixed remove <ip-address> <server> server remove fixed ip <server> <ip-address> Change-Id: Ica07ccf92a76c21fd5608ecaff86ff7c4d96f5a0 Implements: blueprint rework-ip-commands Partial-bug: 1555990 Co-Authored-By: Dean Troyer <dtroyer@gmail.com>
* | | | | | | | | Merge "Transfer "ip floating add/remove" to "server add/remove floating ip""Jenkins2016-07-061-0/+67
|\ \ \ \ \ \ \ \ \ | |/ / / / / / / /
| * | | | | | | | Transfer "ip floating add/remove" to "server add/removeTang Chen2016-07-041-0/+67
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | floating ip" This patch does the following things to transfer "ip floating add/remove" to "server add/remove floating ip": * Add new command "server add/remove floating ip", and unit tests and doc. * Deprecate "ip floating add/remove" command. compute/v2/floatingip.py is not removed because the arguments' positions are different between the new and old commands. * ip floating add <ip-address> <server> server add floating ip <server> <ip-address> * ip floating remove <ip-address> <server> server remove floating ip <server> <ip-address> Change-Id: Ic0dd22ca6fb7b7bc3e820fd5a14d7c551e7ab963 Implements: blueprint rework-ip-commands Partial-bug: 1555990 Co-Authored-By: Dean Troyer <dtroyer@gmail.com>
* | | | | | | | | Merge "Transfer "ip floating pool list" to "floating ip pool list""Jenkins2016-07-062-0/+148
|\ \ \ \ \ \ \ \ \ | |/ / / / / / / /
| * | | | | | | | Transfer "ip floating pool list" to "floating ip pool list"Tang Chen2016-07-042-0/+148
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch does the following things to transfer "ip floating pool list" to "floating ip pool list": * Add a new command "floating ip pool list" to deprecate "ip floating pool list". The source code is in network/v2 dir. * Add doc for "floating ip pool list". * Add floating ip pool unit tests. Change-Id: Id410f4e4a96cf589a6e8def209574da71395b55f Implements: blueprint rework-ip-commands Partial-bug: 1555990 Co-Authored-By: Dean Troyer <dtroyer@gmail.com>
* | | | | | | | | Merge "Add command to unset information from ports"Jenkins2016-07-061-0/+78
|\ \ \ \ \ \ \ \ \ | |_|_|/ / / / / / |/| | | | | | | |
| * | | | | | | | Add command to unset information from portsreedip2016-07-011-0/+78
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch introduces the ``port unset`` command to clear the fixed-ip and binding:profile information from the ports. Implements: blueprint network-property-unset Change-Id: I9dba309234105af477e7618a8a437b7fa3b13cd7
* | | | | | | | | Merge "Refactor unit tests for project and domain with fake classes in ↵Jenkins2016-07-063-298/+343
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | identityv3"
| * | | | | | | | | Refactor unit tests for project and domain with fake classes in identityv3Huanxuan Ao2016-07-043-298/+343
| | |/ / / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add FakeProject and FakeDomain classes and update unit tests for project and domain. Change-Id: Ifeed5dcba03155daa3b7b46b34d49c333ab19135 Partially-Implements: blueprint refactor-identity-unit-test