summaryrefslogtreecommitdiff
path: root/openstackclient/tests/unit
Commit message (Collapse)AuthorAgeFilesLines
...
* | | | | | | | Merge "tests: Add test for multiple blocks devices"Zuul2022-12-051-19/+35
|\ \ \ \ \ \ \ \ | |/ / / / / / / | | | / / / / / | |_|/ / / / / |/| | | | | |
| * | | | | | tests: Add test for multiple blocks devicesStephen Finucane2022-12-011-19/+35
| | |_|/ / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The 'server create' command should support multiple '--block-device' parameters. Prove it. Change-Id: I1bd83287efdbbe11774053b694bae99b6a4ebdf5 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | | Merge "Use the compute SDK in server list"Zuul2022-12-021-136/+125
|\ \ \ \ \ \ | |/ / / / / |/| | | | |
| * | | | | Use the compute SDK in server listDaniel Wilson2022-11-291-136/+125
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update server list to use the compute component of the OpenStack SDK instead of directly using the nova interface. This change depends on SDK version 0.102.0 for automatic client-side query filters. Change-Id: Ib9985812bfd98320b75f3a82bb594a0daa6e4d93
* | | | | | Add test for creating volume from sourcewhoami-rajat2022-11-231-0/+37
| |_|/ / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds a test to create a new volume from source. We also include code changes to pass the right size i.e. either size passed by the user via --size argument or the source volume size. This case is already handled at the API layer[1] but it helps being consistent with passing the right size value as in case of creating a volume from snapshot or backup. [1] https://github.com/openstack/cinder/blob/7c1a5ce7b11964da4537fd6a7d157ede646b9e94/cinder/api/v3/volumes.py#L381-L382 Change-Id: Idc71636dad6bb678fe24f19b0836d2e9bd92d7d2
* | | | | Add option to create volume from backupwhoami-rajat2022-11-211-0/+73
|/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | Support for creating a volume from backup was added in microversio 3.47. This patch adds a --backup option to the volume create command to add that support. Change-Id: Ib26d2d335475d9aacbf77c0fd7b7cda2ba743943
* | | | Merge "image: Add 'image stage' command"Zuul2022-11-162-25/+80
|\ \ \ \ | |/ / /
| * | | image: Add 'image stage' commandStephen Finucane2022-11-092-25/+80
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the equivalent of the 'image-stage' glanceclient command. Change-Id: I10b01ef145740a2f7ffe5a8c7ce0296df0ece0bd Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | Merge "image: Simplify handling of data provided via stdin"Zuul2022-11-161-64/+30
|\ \ \ \ | |/ / /
| * | | image: Simplify handling of data provided via stdinStephen Finucane2022-11-091-64/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This was unnecessarily complex. Change-Id: I8289d5ce7356d8bc89425590a7f71bca91a6d396 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | Merge "image: Ignore '--progress' if providing image data from stdin"Zuul2022-11-161-0/+31
|\ \ \ \ | |/ / /
| * | | image: Ignore '--progress' if providing image data from stdinStephen Finucane2022-11-091-0/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | You can provide data via stdin when creating an image. Using this with '--progress' makes no sense and causes an error currently. Fix this. Change-Id: I3c2d658b72a7c62931b779b0d19bb97f60a0c655 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | Merge "Moved hypervisor to the SDK"Zuul2022-11-162-163/+201
|\ \ \ \
| * | | | Moved hypervisor to the SDKViolet Kurtz2022-11-092-163/+201
| | | | | | | | | | | | | | | | | | | | Change-Id: Ie955fb4d27c30e044626732a1f3e0f141cb85aa5
* | | | | Merge "Use the compute SDK in usage commands"Zuul2022-11-161-27/+18
|\ \ \ \ \
| * | | | | Use the compute SDK in usage commandsDaniel Wilson2022-10-251-27/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update usage list and usage show to use the compute component of the OpenStack SDK instead of directly using the nova interface. Change-Id: I1c4d2247c9c1a577ed9efad7e8332e7c9b974ad5
* | | | | | compute: Add missing microversion check for networksStephen Finucane2022-11-081-17/+83
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The 'auto' and 'none' network allocation policies are only supported on compute API microversion 2.37 or later. Enforce this in the code. Change-Id: I90f8fb1e61ead4bd406ea76bbeb731b913805b13 Signed-off-by: Stephen Finucane <sfinucan@redhat.com> Story: 2010385 Task: 46657
* | | | | | compute: Fix '--network none/auto' handlingStephen Finucane2022-11-081-12/+37
| |_|/ / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This should lookup a network called 'none' or 'auto', not do the equivalent on '--nic none' or '--nic auto'. Correct this. Change-Id: I3c5acc49bfe8162d8fb6110603da56d56090b78f Signed-off-by: Stephen Finucane <sfinucan@redhat.com> Story: 2010385 Task: 46658
* | | | | Merge "compute: Add '--no-network', '--auto-network' flags"Zuul2022-11-081-14/+44
|\ \ \ \ \
| * | | | | compute: Add '--no-network', '--auto-network' flagsStephen Finucane2022-10-261-14/+44
| |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These are aliases for '--nic none' and '--nic auto', respectively. Change-Id: I7b4f7e5c3769a813bd8b2b9cd6090c6fe501e13d Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | Merge "quota: Deprecate "force" behavior for network quotas"Zuul2022-11-051-3/+4
|\ \ \ \ \
| * | | | | quota: Deprecate "force" behavior for network quotasStephen Finucane2022-10-111-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In change Idc1b99492d609eb699d0a6bef6cd760458a774f6, we added a '--check-limit' option to enable "no force" behavior for network quotas. This was already the default for compute quotas. Provide a path for harmonizing the behavior of the two options by instead using a '--no-force' option which will become the eventual default for the network quotas also. Change-Id: I25828a3d68e2e900f498e17a0d01fb70be77548e Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | | Merge "quota: Fix issues with delete quota command"Zuul2022-11-051-13/+14
|\ \ \ \ \ \
| * | | | | | quota: Fix issues with delete quota commandStephen Finucane2022-10-111-13/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We were passing a project object rather than just the ID. Also correct a typo in the call to delete network quotas. Change-Id: I2292db7932ec01026f0e54014e3d02218792617a Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | | | Merge "tests: Remove unnecessary nesting of volume resources"Zuul2022-11-0534-2567/+2378
|\ \ \ \ \ \ \ | |/ / / / / /
| * | | | | | tests: Remove unnecessary nesting of volume resourcesStephen Finucane2022-09-3034-2567/+2378
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I210ce7534d161e89115e5cb96e42ab7f27170aa1 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | | | Merge "tests: Remove duplicate FakeImagev1Client"Zuul2022-11-051-7/+4
|\ \ \ \ \ \ \ | |/ / / / / /
| * | | | | | tests: Remove duplicate FakeImagev1ClientStephen Finucane2022-09-301-7/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I guess this was defined to avoid a circular import. There are easier ways to do this. Change-Id: Iab215a53691298413ea9d10def792008ab9edbce Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | | | Merge "tests: Move fake clients to top of file"Zuul2022-11-053-123/+123
|\ \ \ \ \ \ \ | |/ / / / / /
| * | | | | | tests: Move fake clients to top of fileStephen Finucane2022-09-303-123/+123
| |/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These are important and they're easier to identify at the top of the file than nested deep inside. Change-Id: I1569c855fadfe4cdacf83ee07d08922bf3edefbc Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | | Merge "quota: Allow showing project-specific quotas"Zuul2022-11-051-0/+62
|\ \ \ \ \ \ | |/ / / / / | | | | / / | |_|_|/ / |/| | | |
| * | | | quota: Allow showing project-specific quotasStephen Finucane2022-09-301-0/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add '--compute', '--network' and '--volume' options to the 'quota show' command, along with a default '--all' option, allowing us to restrict quotas shown to an individual service. Change-Id: I122b765df01887b8d916ee6567ffb7768fcb4392 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | Merge "Added "openstack image metadefs namespace list" command"Zuul2022-10-262-0/+121
|\ \ \ \ \
| * | | | | Added "openstack image metadefs namespace list" commandAreg Grigoryan2022-10-262-0/+121
| | |/ / / | |/| | | | | | | | | | | | | | | | | | Change-Id: Ibc064566478818bd70e7e6550095d24a05e1bb0e Depends-On: https://review.opendev.org/c/openstack/openstacksdk/+/854612
* | | | | Merge "volume: Volume names are optional"Zuul2022-10-261-3/+1
|\ \ \ \ \ | |/ / / / |/| | | |
| * | | | volume: Volume names are optionalStephen Finucane2022-09-141-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Who knew? Change-Id: I1c1a811c0db59250e8a20a87f25c2662bc3ab3e8 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | Merge "quota: Add 'quota show --usage' option"Zuul2022-10-121-14/+54
|\ \ \ \ \ | | |/ / / | |/| | |
| * | | | quota: Add 'quota show --usage' optionStephen Finucane2022-09-301-14/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Provide an more sane way to get usage information for a particular project's quotas. This requires using the 'Lister' command type since the 'ShowOne' command type only allows for simple key-value pair output. We also add a note indicating that the '<project>' argument is optional. Change-Id: Ic7342cf08f024cc690049414c5eef5b9a7594677 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | Merge "quota: Simplify logic used to list, show quotas"Zuul2022-10-121-23/+0
|\ \ \ \ \ | |/ / / /
| * | | | quota: Simplify logic used to list, show quotasStephen Finucane2022-09-301-23/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is prep work for some changes we're introducing in a later change. Change-Id: I27a59bc1d57e6815fb166fb99ea2af88f08b68a9 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | Merge "quota: Add support for detailed volume quotas"Zuul2022-10-072-3/+63
|\ \ \ \ \ | |/ / / /
| * | | | quota: Add support for detailed volume quotasStephen Finucane2022-09-302-3/+63
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We were stating that this was not supported. That is not true. Correct the oversight. Change-Id: Ib9d9db641a18e142be0a1eccff783e7cccdf2db5 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | Merge "quota: Add 'quota delete' command"Zuul2022-10-071-0/+107
|\ \ \ \ \ | |/ / / /
| * | | | quota: Add 'quota delete' commandStephen Finucane2022-09-301-0/+107
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We had previously indicated that people use 'quota set' for unsetting a project's quotas, however, there was nothing that actually allowed us to do this. Correct that oversight. Change-Id: I04057e766b8ccf94bf219972249b68dc2bb796d4 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | Merge "Speed up standard flavor list command"Zuul2022-09-301-0/+57
|\ \ \ \ \
| * | | | | Speed up standard flavor list commandPavlo Shchelokovskyy2022-09-301-0/+57
| |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | currently this command tries to fetch extra_specs for any flavor that does not have them (which is quite usual), regardless if the command was even asked to display them (--long) at all. This significantly slows down this command as it makes a lot of unnecessary REST calls, one per each flavor to fetch extra_specs for. With this patch, client only attempts to fetch flavor extra_specs if the user actually called the client with --long. Change-Id: Ia36414d891a41b641d7a9a04f0a1e7d43cfee351 Story: 2010343 Task: 46484
* | | | | Merge "compute: Only retrieve necessary images"Zuul2022-09-301-5/+19
|\ \ \ \ \
| * | | | | compute: Only retrieve necessary imagesStephen Finucane2022-04-121-5/+19
| | |_|_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Glance API allows us to filter by multiple IDs using the 'in:' operator. Take advantage of this to speed up listing of server in larger deployments where image counts in the hundreds (or even thousands) are not uncommon. Unfortunately the Nova API does not support something similar for listing flavors. Boo. Change-Id: I7d3222d0b0b8bf72b4ff3e429bc49e621b569979 Signed-off-by: Stephen Finucane <sfinucan@redhat.com> Depends-On: https://review.opendev.org/c/openstack/openstacksdk/+/837613
* | | | | Merge "Add authorization_ttl for identity providers"Zuul2022-09-301-0/+170
|\ \ \ \ \
| * | | | | Add authorization_ttl for identity providersPavlo Shchelokovskyy2022-07-131-0/+170
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | this is supported since Ussuri (Keystone API version 3.14) but was lacking from openstackclient. Change-Id: Ifac818b9a4eff66d9a68455ada1ddfe67cb46b3b