This method is based only on tempest configuration, so better to
move it under utils.py method that other classes will benefit it
without having to inherit from it.
Change-Id: Ia0cf15210e697988cd54ae82db8bb76aa17a5996
As a follow-up to the patch [1].
Better to move these methods under utils file
so other classes can benefit from it.
[1] Ia0cf15210e697988cd54ae82db8bb76aa17a5996
Change-Id: I31322352dcd7982443fa1f590a643b341c059ff0
1) Use the shares_v2_client to make metadata API requests.
This allows us to test v1 proxies as well where appropriate,
and actually test the supported version of the API instead
of the deprecated version
2) Verify key in GET /v2/shares/<share>/metadata/{key} API
the client's _parse_body helper strips out the top
level key allowing us to miss bugs associated with
any key changes from the server [1]. Allow for opt-in
verification of the key and add this verification
to the affected API.
[1] https://bugs.launchpad.net/manila/+bug/1968069
Depends-On: Ib5a62599b84ba55617071f8bcd8e2a1a11b2537b
Change-Id: I7b1af957f08328c642a74ff123deb78e193bbe3a
Related-Bug: #1968069
Signed-off-by: Goutham Pacha Ravi <gouthampravi@gmail.com>
This change adds negative and positive functional tests
for the new feature add multiple subnets per az. Older
functional tests impacted by the feature are fixed. Finally,
the new flags `run_share_server_multiple_subnets_tests` and
`run_network_allocation_update_tests` are added and configured
in the community jobs for Dummy DHSS=True and Container Driver.
Partially-Implements: blueprint multiple-share-network-subnets
Change-Id: I99547e1873646fb1494a454f67b14c7293342beb
API tests must be evaluated by min and max
versions, however, we've multiple places
where we don't seem to evaluate the min_version;
this leads to incorrect behavior when test
runners set a different min_version in their
test configuration.
We can also consolidate the decorators and
callables that we have. We attempted this in
the recent past [1], however, we replaced the
callables with calling a decorator method, which
resulted in many tests not being skipped.
This bugfix is currently necessary to get
tests working against stable/ussuri and
stable/train branches.
[1] I0c35aff993e67c1ef44c27580f8c2c829a6275f7
Change-Id: I2eceb1d5fe42b1b779e115a0144a5d9639d3753f
Signed-off-by: Goutham Pacha Ravi <gouthampravi@gmail.com>
Several calls to ddt.data() change the lists of items into a set
to de-duplicate them. This happens, for example, when the list
constains microversions which may come from some variable.
In order to generate a consistent and predictable list of tests,
which can be compared over time (as ddt adds the index of the
test to the test name), replace the usage of set with
a new function which removes the duplicates but keeps the order.
Change-Id: I9cbd26016238c25487ac8104c1188cd2cf4f467e
This package adds 3 new flake8 warnings
* ``I100``: Your import statements are in the wrong order.
* ``I101``: The names in your from import are in the wrong order.
* ``I201``: Missing newline between sections or imports.
Change-Id: I4feabcd4db583d213e0e4d414eee267b0ddb8870
The share groups functionality will no longer be considered
experimental. The existent functional tests were modified to accomplish
with this feature graduation.
Change-Id: Ideba68c0481345e808f185195eea68e879155cf1
Partially-Implements: bp graduate-share-groups-feature
- Updates the existent functional tests to accomplish with the two
new quotas for share replicas.
- Add new functional tests for share replicas
Depends-On: I8ba7bc6f167c28d6c169b2187d0e1bda7cad3f69
Change-Id: I9c5df364bca666bbc32fb10b100a38f78888088a
Manila tempest plugin class structure should be compatible
with tempest project as manila tempest plugin is a plugin
of tempest.
In some cases incompatibility can cause problems.
For example: using "check_uuid" tool for generating UUIDs
for tests does not work properly in manila, Because some
classes are wrapped with conditions skipped.
I suggest to use "skip_checks" method that been used to
evaluate config before tests methods and skip them based
on these checks.
This patch moves all conditions under this method.
Two new functions been added to "skip_checks" method
in order to skip by microversions and reduce a duplicated
code:
- "check_skip_with_microversion"
- "check_skip_with_microversion_not_supported"
Change-Id: Id0a15dbfbd3d85d7773c26e252f4cc4d906cf377
This patch adds functional test for share-network-subnets and
validates the new API version 2.51
Change-Id: I60bdb493ad5766f28408a0c877f960922fe44ad0
Partially-implements: bp share-network-multiple-subnets
This patch enables share-replica tests to be executed in a multitenancy
environment, providing a share-network to be used by both shares and
share-replicas.
The multitenancy test for share-replicas will be enabled only for API
version equal or greater than 2.51.
Depends-On: I60bdb493ad5766f28408a0c877f960922fe44ad0
Change-Id: Icb93fc346b71edc7bb3ac989e9751899bb80fbe5
This patch adds functional tests for managing/unmanaging
share servers, shares, and snapshots in DHSS=True.
Change-Id: I452c2a99b186f53d737cb7fbd7eabfcfd9b249d6
Partially-implements: bp manage-unmanage-with-share-servers
Tempest assumes a default share type already created
to work. This means, if a default share type is not
created and not specified in the conf file, tempest
tests fail. A workaround is to create a share type
as part of the environment setup for all the tests
that need it. This patch set does that.
Change-Id: I15880e400df30918762ebd7304244b4a27200168
Closes-Bug: #1743472
Please read spec for design detail [1].
Add support to validate IPv6 based addresses
in allow access API when access type is IP.
[1] f7202a6cfe32a057f752a4e393f848f8a0211c36
APIImpact
DocImpact
Change-Id: Ica242007e77a7e21b2151e5fc32401b501d961b2
Partial-Implements: blueprint support-ipv6-access
Improve coverage by adding tests that validate the share-type
change while also changing the driver mode.
Closes-bug: #1620800
Change-Id: I924c34aa69591754b437d75f43db91d77e73fb07
Tempest tests were not appropriate for driver-assisted migration,
so this was fixed.
Also, improved docstrings and fixed workflow for drivers when
implementing 2-phase migration to be accurate with tempest and
handle AZs, which were previously locked to the source share's
AZ.
Driver-assisted migration now creates an additional
share instance to better handle and support driver methods.
Updated allow_access and deny_access APIs to allow users to mount
migrating shares before issuing 'migration-complete'.
APIImpact
Closes-bug: #1594922
Change-Id: If4bfaf7e9d963b83c13a6fea241c2eda14f7f409
Add APIs to support manage and unmanage share snapshots.
Also add support in the Generic driver.
This only supports for DHSS=False driver mode.
Add provider_location column to the share_snapshots table
to save data used to identify the snapshot on the backend.
Also need to bump microversion.
APIImpact
DocImpact
Change-Id: I87a066173c85d969607d132accd9f0e9bd49c235
Implements: blueprint manage-unmanage-snapshot
Manila microversions have following template:
x.y
where 'x' and 'y' both digits.
And now tempest transforms string 'x.y' to float but it is incorrect
thing to do because float assumes that each left value is bigger than
right one. And it is not suitable for microversion comparisons.
Examples:
Microversions true conditions:
2.9 < 2.10
2.9 < 2.81
Float true conditions:
2.9 > 2.10
2.9 > 2.81
So, create new file 'manila_tempest_tests/utils.py' and place there
old and new functions that serve all microversion actions. In addition,
port another existing utility function called 'rand_ip'.
Change-Id: I88bf2cb51fd8de1bc89bf169bda7a05ca5a0b8ab
Closes-Bug: #1518996