summaryrefslogtreecommitdiff
path: root/openstackclient/tests
Commit message (Collapse)AuthorAgeFilesLines
...
* | | | | Merge "volume: Add more missing 'volume backup *' options"Zuul2021-06-212-1/+159
|\ \ \ \ \
| * | | | | volume: Add more missing 'volume backup *' optionsStephen Finucane2021-06-102-1/+159
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add an additional '--no-property' option to the 'volume backup set' command, along with a brand spanking new 'volume backup unset' command. Change-Id: Id7ca925e0ada03e259f0ecaf3e02af11c900641e Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | | Merge "volume: Add 'volume group snapshot *' commands"Zuul2021-06-212-0/+315
|\ \ \ \ \ \ | |/ / / / /
| * | | | | volume: Add 'volume group snapshot *' commandsStephen Finucane2021-06-102-0/+315
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These mirror the 'cinder group-snapshot-*' commands, with arguments copied across essentially verbatim. The only significant departure is the replacement of "tenant" terminology with "project". volume group snapshot create volume group snapshot delete volume group snapshot list volume group snapshot show Change-Id: Ia5084749b7c1a5a936fd6d6e8d89b9b80969f68c Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | | Merge "volume: Add 'volume group type *' commands"Zuul2021-06-212-1/+478
|\ \ \ \ \ \ | |/ / / / /
| * | | | | volume: Add 'volume group type *' commandsStephen Finucane2021-06-032-1/+478
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These mirror the 'cinder group-type-*' commands, with arguments copied across essentially verbatim. The only significant departure is the merging of some commands, such as 'group-type-default' and 'group-type-list' into 'group type list', and 'group-type-update' and 'group-type-key' into 'group type set/unset'. volume group type create volume group type delete volume group type list volume group type show volume group type set volume group type unset Change-Id: Iee6ee2f1f276e6ef6f75a74f8f2980f14c0d5e2f Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | | Merge "volume: Add 'volume group *' commands"Zuul2021-06-182-0/+608
|\ \ \ \ \ \ | |/ / / / /
| * | | | | volume: Add 'volume group *' commandsStephen Finucane2021-06-032-0/+608
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These mirror the 'cinder group-*' commands, with arguments copied across essentially verbatim. The only significant departures are the replacement of "tenant" terminology with "project" and the merging of the various volume group replication action commands into the parent volume group (e.g. 'openstack volume group set --enable-replication' instead of 'cinder group enable-replication') volume group create volume group delete volume group list volume group show volume group set volume group failover Change-Id: I3b2c0cb92b8a53cc1c0cefa3313b80f59c9e5835 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | | Merge "tests: Rename 'FakeType' -> 'FakeVolumeType'"Zuul2021-06-188-84/+91
|\ \ \ \ \ \ | |/ / / / /
| * | | | | tests: Rename 'FakeType' -> 'FakeVolumeType'Stephen Finucane2021-06-038-84/+91
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There are more types than just volume types. Change-Id: I6af66f966a221437ff79fabcb0b81fd38586fe67 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | | Merge "volume: Add missing 'volume backup *' options"Zuul2021-06-181-5/+150
|\ \ \ \ \ \ | |/ / / / /
| * | | | | volume: Add missing 'volume backup *' optionsStephen Finucane2021-06-031-5/+150
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a couple of missing options to each command: volume backup create --no-incremental --property --availability-zone volume backup set --property Most of these are version dependent so we add the relevant version checks as part of this work. While we're here, we also make the formatting a little easier on the eye in places. Change-Id: I328d5c981cb32b2ee9a4b1bd43aa36b22347ff63 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | | Merge "volume: Add 'volume message *' commands"Zuul2021-06-182-0/+392
|\ \ \ \ \ \ | |/ / / / /
| * | | | | volume: Add 'volume message *' commandsStephen Finucane2021-06-032-0/+392
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch implements the necessary commands to utilize the Messages API introduced in Cinder API version 3.3. Version 3.5 built upon this by implementing pagination support for these commands which is present in this patch as well. volume message get volume message list volume message delete Change-Id: I64aa0b4a8d4468baa8c63e5e30ee31de68df999d
* | | | | | Merge "volume: Add 'volume attachment *' commands"Zuul2021-06-182-0/+715
|\ \ \ \ \ \ | |/ / / / / | | | / / / | |_|/ / / |/| | | |
| * | | | volume: Add 'volume attachment *' commandsStephen Finucane2021-06-032-0/+715
| | |_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These mirror the 'cinder attachment-*' commands, with arguments copied across essentially verbatim. The only significant departure is the replacement of "tenant" terminology with "project". volume attachment create volume attachment delete volume attachment list volume attachment complete volume attachment set volume attachment show Full support for filtering is deferred for now since that's a more complicated change that requires additional commands be added first. TODOs are included to this effect. Change-Id: If47c2b56fe65ee2cee07c000d6ae3688d5ef3b42 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | Add support for Neutron's L3 conntrack helper resourceSlawek Kaplonski2021-06-073-0/+536
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Neutron has got CRUD API for L3 conntrack helper since some time. This patch adds support for it in the OSC. OpenStack SDK supports that since [1] This patch also bumps minimum OpenStack SDK version to the 0.56.0 as that version introduced support for the Neutron's L3 conntrack helper. [1] https://review.opendev.org/c/openstack/openstacksdk/+/782870 Change-Id: I55604182ae50b6ad70c8bc1f7efad8859f191269
* | | Allow to send extra attributes in Neutron related commandsSlawek Kaplonski2021-05-262-0/+198
|/ / | | | | | | | | | | | | | | | | | | To deprecate and drop support for neutronclient CLI and use only OSC we need feature parity between OSC and neutronclient. Last missing piece here is possibility to send in POST/PUT requests unknown parameters to the Neutron server. This patch adds such possibility to the OSC. Change-Id: Iba09297c2be9fb9fa0be1b3dc65755277b79230e
* | Merge "volume: Re-add accidentally deleted test"Zuul2021-04-061-0/+742
|\ \
| * | volume: Re-add accidentally deleted testStephen Finucane2021-03-191-0/+742
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is essentially a partial revert of change I94aa7a9824e44f9585ffb45e5e7637b9588539b4, which removed some deprecated commands like 'openstack snapshot *' in favour of 'openstack volume snapshot *'. Unfortunately the latter appeared to have no test coverage and were relying on tests for the former to validate behavior. Re-add the tests removed back then. Change-Id: Ib2cd975221034c8997d272d43cfb18acefc319fe Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | Merge "Implements hide image"Zuul2021-04-011-0/+68
|\ \ \
| * | | Implements hide imageValery Tschopp2021-03-251-0/+68
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | openstack image set [--hidden|--unhidden] IMAGE openstack image list --hidden Task: 41734 Story: 2008581 Change-Id: Ie84f10c0f7aa2e7b7f78bfadc70132a10673866e
* | | | Merge "Remove unnecessary test"Zuul2021-03-201-30/+0
|\ \ \ \ | |_|/ / |/| | |
| * | | Remove unnecessary testStephen Finucane2020-11-061-30/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As noted, we're simply testing the default behavior of Python 3 in this test. Remove it, now that this is the only version(s) of Python 3 we have to worry about. Change-Id: I5f07343df8334457d907086033d5685f59c0bf0e Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | Merge "project cleanup"5.5.0Zuul2021-03-181-0/+183
|\ \ \ \
| * | | | project cleanupArtem Goncharov2021-02-021-0/+183
| | |/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | New implementation of the project cleanup based on the sdk.project_cleanup. It is implemented as an additional OSC operation and will ideally obsolete the `openstack project purge` giving flexibility to extend services support, parallelization, filters, etc. Change-Id: Ie08877f182379f73e5ec5ad4daaf84b3092c829c
* | | | compute: Remove 'file://' prefix from '--block-device'Stephen Finucane2021-03-111-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There are a couple of other (networking-related) options which accept paths, none of which insist on a URI-style path. Let's just drop this bit of complexity before we release the feature. Change-Id: Ia7f781d82f3f4695b49b55a39abbb6e582cd879c Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | Merge "compute: Add support for loading BDMs from files"Zuul2021-03-111-0/+83
|\ \ \ \
| * | | | compute: Add support for loading BDMs from filesStephen Finucane2021-03-051-0/+83
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The syntax of the '--block-device' parameter is complex and easily screwed up. Allow users to load a block device config from a file. For example: $ openstack server create ... --block-device file:///tmp/bdm.json ... This should alleviate the pain that is BDMv2 somewhat. No functional tests are provided since we already have tests for the CSV style of passing parameters and the unit tests show that the net result is the same. Change-Id: I3e3299bbdbbb343863b4c14fb4d9196ff3e1698d Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | Merge "compute: Add functional tests for --block-device"Zuul2021-03-112-38/+154
|\ \ \ \ \ | |/ / / /
| * | | | compute: Add functional tests for --block-deviceStephen Finucane2021-03-052-38/+154
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This mostly reuses the existing tests for '--block-device-mapping', which can hopefully be removed at some point in the future. This highlights two issues with the implementation of this option. Firstly, the 'boot_index' parameter is not required so don't mandate it. Secondly, and more significantly, we were defaulting the destination type for the 'image' source type to 'local'. Nova only allows you to attach a single image to local mapping [1], which means this default would only make sense if you were expecting users to use the '--block-device' option exclusively and omit the '--image' option. This is the *less common* case so this is a bad default. Default instead to a destination type of 'volume' like everything else, and require users specifying '--block-device' alone to pass 'destination_type=local' explicitly. [1] https://github.com/openstack/nova/blob/c8a6f8d2e/nova/block_device.py#L193-L206 Change-Id: I1718be965f57c3bbdb8a14f3cfac967dd4c55b4d Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | network: Add missing subnet unset --gateway <subnet-id>Bharat Kunwar2021-03-051-0/+4
|/ / / / | | | | | | | | | | | | | | | | | | | | Story: 2008695 Task: 42003 Change-Id: I9486a09531b11f27a9ff0d68fd4ad8c68a65cccf
* | | | Merge "compute: Remove deprecated 'server migrate --live' option"Zuul2021-03-041-163/+40
|\ \ \ \
| * | | | compute: Remove deprecated 'server migrate --live' optionStephen Finucane2021-01-221-163/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's been long enough. Time to remove this. Change-Id: I37ef09eca0db9286544a4b0bb33f845311baa9b2 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | Merge "compute: Stop silently ignore --(no-)disk-overcommit"Zuul2021-03-041-0/+34
|\ \ \ \ \ | |/ / / /
| * | | | compute: Stop silently ignore --(no-)disk-overcommitStephen Finucane2021-01-221-0/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These options are not supported from Nova API microversion 2.25 and above. This can be a source of confusion. Start warning, with an eye on erroring out in the future. Change-Id: I53f27eb3e3c1a84d0d77a1672c008d0e8bb8536f Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | Merge "compute: Auto-configure shared/block live migration"Zuul2021-03-041-20/+25
|\ \ \ \ \ | |/ / / /
| * | | | compute: Auto-configure shared/block live migrationStephen Finucane2021-01-221-20/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | API microversion 2.25 introduced the 'block_migration=auto' value for the os-migrateLive server action. This is a sensible default that we should use, allowing users to avoid stating one of the '--block-migration' or '--shared-migration' parameters explicitly. While we're here, we take the opportunity to fix up some formatting in the function, which is really rather messy. Change-Id: Ieedc77d6dc3d4a3cd93b29672faa97dd4e8c1185 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | Merge "compute: Add 'server create --block-device' option"Zuul2021-03-041-0/+256
|\ \ \ \ \ | |/ / / /
| * | | | compute: Add 'server create --block-device' optionStephen Finucane2021-01-221-0/+256
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | One of the last big gaps with novaclient. As noted in the release note, the current '--block-device-mapping' format is based on the old BDM v1 format, even though it actually results in BDM v2-style requests to the server. It's time to replace that. Change-Id: If4eba38ccfb208ee186b90a0eec95e5fe6cf8415 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | Merge "compute: Add missing 'server create' options"Zuul2021-03-041-0/+233
|\ \ \ \ \ | |/ / / /
| * | | | compute: Add missing 'server create' optionsStephen Finucane2021-01-211-0/+233
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add some volume-related options, namely '--snapshot', '--swap', and '--ephemeral'. All are shortcuts to avoid having to use '--block-device-mapping'. Change-Id: I450e429ade46a7103740150c90e3ba9f2894e1a5 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | Merge "compute: Improve 'server create --block-device-mapping' option parsing"Zuul2021-03-041-29/+76
|\ \ \ \ \ | |/ / / /
| * | | | compute: Improve 'server create --block-device-mapping' option parsingStephen Finucane2021-01-211-29/+76
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Once again, custom actions to the rescue. Change-Id: I6b4f80882dbbeb6a2a7e877f63becae7211b7f9a Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | Merge "compute: Rename 'server migrate (confirm|revert)'"Zuul2021-03-041-0/+152
|\ \ \ \ \ | |/ / / /
| * | | | compute: Rename 'server migrate (confirm|revert)'Stephen Finucane2021-01-211-0/+152
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We're confirming or reverting a server migration, not a server migrate. We've a number of 'server migration *' commands now so it makes sense to move them under here. Change-Id: Ib95bb36511dad1aafe75f0c88d10ded382e4fa5c Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | Merge "compute: Add 'server migration show' command"Zuul2021-03-042-0/+171
|\ \ \ \ \ | |/ / / /
| * | | | compute: Add 'server migration show' commandStephen Finucane2021-01-212-0/+171
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This replaces the 'server-migration-show' command provided by novaclient. Change-Id: I413310b481cc13b70853eb579417f6e6fad10d98 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
* | | | | Merge "Rename FakeServerMigration to FakeMigration"Zuul2021-03-042-12/+12
|\ \ \ \ \ | |/ / / /
| * | | | Rename FakeServerMigration to FakeMigrationStephen Finucane2021-01-212-12/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Server migrations are (confusingly) a different thing returned by a different API. Change-Id: Ib6b7c8f9cc3d1521a993616f832d41651dc46f73 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>